Skip to content

Commit

Permalink
feat(dask): update reana.yaml schema (reanahub#467)
Browse files Browse the repository at this point in the history
  • Loading branch information
Alputer committed Oct 16, 2024
1 parent f520dc3 commit fc58884
Show file tree
Hide file tree
Showing 2 changed files with 128 additions and 2 deletions.
117 changes: 117 additions & 0 deletions reana_commons/openapi_specifications/reana_server.json
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,34 @@
"slurmcern"
]
},
"dask_cluster_default_cores_limit": {
"title": "Default cores limit for dask clusters",
"value": "4"
},
"dask_cluster_default_memory_limit": {
"title": "Default memory limit for dask clusters",
"value": "2Gi"
},
"dask_cluster_default_single_worker_cores": {
"title": "Number of cores for one dask worker by default",
"value": "0.5"
},
"dask_cluster_default_single_worker_memory": {
"title": "Amount of memory for one dask worker by default",
"value": "256Mi"
},
"dask_cluster_max_cores_limit": {
"title": "Maximum cores limit for dask clusters",
"value": "8"
},
"dask_cluster_max_memory_limit": {
"title": "Maximum memory limit for dask clusters",
"value": "4Gi"
},
"dask_enabled": {
"title": "Dask workflows allowed in the cluster",
"value": "False"
},
"default_kubernetes_jobs_timeout": {
"title": "Default timeout for Kubernetes jobs",
"value": "604800"
Expand Down Expand Up @@ -479,6 +507,83 @@
},
"type": "object"
},
"dask_cluster_default_cores_limit": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"dask_cluster_default_memory_limit": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"dask_cluster_default_single_worker_cores": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"dask_cluster_default_single_worker_memory": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"dask_cluster_max_cores_limit": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"dask_cluster_max_memory_limit": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"dask_enabled": {
"properties": {
"title": {
"type": "string"
},
"value": {
"type": "string"
}
},
"type": "object"
},
"default_kubernetes_jobs_timeout": {
"properties": {
"title": {
Expand Down Expand Up @@ -574,6 +679,18 @@
"type": "object"
}
},
"required": [
"compute_backends",
"default_kubernetes_jobs_timeout",
"default_kubernetes_memory_limit",
"default_workspace",
"kubernetes_max_memory_limit",
"maximum_interactive_session_inactivity_period",
"maximum_kubernetes_jobs_timeout",
"maximum_workspace_retention_period",
"workspaces_available",
"dask_enabled"
],
"type": "object"
}
},
Expand Down
13 changes: 11 additions & 2 deletions reana_commons/validation/schemas/reana_analysis_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,19 @@
"memory": {
"type": "string",
"description": "Amount of memory to be used by the workflow. If not needed, autoscaler can choose to use less memory.",
"pattern": "^[1-9][0-9]*[EPTGMK]$"
"pattern": "^[1-9][0-9]*(Ei|Pi|Ti|Gi|Mi|Ki|E|P|T|G|M|K)$"
},
"single_worker_cores": {
"type": "number",
"description": "Cores for one dask worker."
},
"single_worker_memory": {
"type": "string",
"description": "Memory for one dask worker.",
"pattern": "^[1-9][0-9]*(Ei|Pi|Ti|Gi|Mi|Ki|E|P|T|G|M|K)$"
}
},
"required": ["image", "cores", "memory"]
"required": ["image"]
}
},
"additionalProperties": false
Expand Down

0 comments on commit fc58884

Please sign in to comment.