prefect_databricks.jobs
This is a module containing tasks for interacting with:
Databricks jobs
Functions
jobs_runs_export
run_id: The canonical identifier for the run. This field is required.databricks_credentials: Credentials to use for authentication with Databricks.views_to_export: Which views to export (CODE, DASHBOARDS, or ALL). Defaults to CODE.
- Upon success, a dict of the response.
views: List["models.ViewItem"]
API Endpoint:
/2.0/jobs/runs/export
API Responses:
| Response | Description |
|---|---|
| 200 | Run was exported successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_create
databricks_credentials: Credentials to use for authentication with Databricks.name: An optional name for the job, e.g.A multitask job.tags: A map of tags associated with the job. These are forwarded to the cluster as cluster tags for jobs clusters, and are subject to the same limitations as cluster tags. A maximum of 25 tags can be added to the job, e.g.
tasks: A list of task specifications to be executed by this job, e.g.
job_clusters: A list of job cluster specifications that can be shared and reused by tasks of this job. Libraries cannot be declared in a shared job cluster. You must declare dependent libraries in task settings, e.g.
email_notifications: An optional set of email addresses that is notified when runs of this job begin or complete as well as when this job is deleted. The default behavior is to not send any emails. Key-values:- on_start:
A list of email addresses to be notified when a run begins.
If not specified on job creation, reset, or update, the list
is empty, and notifications are not sent, e.g.
- on_success:
A list of email addresses to be notified when a run
successfully completes. A run is considered to have
completed successfully if it ends with a
TERMINATEDlife_cycle_stateand aSUCCESSFULresult_state. If not specified on job creation, reset, or update, the list is empty, and notifications are not sent, e.g. - on_failure:
A list of email addresses to notify when a run completes
unsuccessfully. A run is considered unsuccessful if it ends
with an
INTERNAL_ERRORlife_cycle_stateor aSKIPPED,FAILED, orTIMED_OUTresult_state. If not specified on job creation, reset, or update, or the list is empty, then notifications are not sent. Job-level failure notifications are sent only once after the entire job run (including all of its retries) has failed. Notifications are not sent when failed job runs are retried. To receive a failure notification after every failed task (including every failed retry), use task-level notifications instead, e.g. - no_alert_for_skipped_runs:
If true, do not send email to recipients specified in
on_failureif the run is skipped. webhook_notifications: A collection of system notification IDs to notify when runs of this job begin or complete. The default behavior is to not send any system notifications. Key-values:- on_start:
An optional list of notification IDs to call when the run
starts. A maximum of 3 destinations can be specified for the
on_startproperty, e.g. - on_success:
An optional list of notification IDs to call when the run
completes successfully. A maximum of 3 destinations can be
specified for the
on_successproperty, e.g. - on_failure:
An optional list of notification IDs to call when the run
fails. A maximum of 3 destinations can be specified for the
on_failureproperty, e.g. timeout_seconds: An optional timeout applied to each run of this job. The default behavior is to have no timeout, e.g.86400.schedule: An optional periodic schedule for this job. The default behavior is that the job only runs when triggered by clicking “Run Now” in the Jobs UI or sending an API request torunNow. Key-values:- quartz_cron_expression:
A Cron expression using Quartz syntax that describes the
schedule for a job. See [Cron Trigger](http://www.quartz-
scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html)
for details. This field is required, e.g.
20 30 * * * ?. - timezone_id:
A Java timezone ID. The schedule for a job is resolved with
respect to this timezone. See Java
TimeZone
for details. This field is required, e.g.
Europe/London. - pause_status:
Indicate whether this schedule is paused or not, e.g.
PAUSED. max_concurrent_runs: An optional maximum allowed number of concurrent runs of the job. Set this value if you want to be able to execute multiple runs of the same job concurrently. This is useful for example if you trigger your job on a frequent schedule and want to allow consecutive runs to overlap with each other, or if you want to trigger multiple runs which differ by their input parameters. This setting affects only new runs. For example, suppose the job’s concurrency is 4 and there are 4 concurrent active runs. Then setting the concurrency to 3 won’t kill any of the active runs. However, from then on, new runs are skipped unless there are fewer than 3 active runs. This value cannot exceed 1000. Setting this value to 0 causes all new runs to be skipped. The default behavior is to allow only 1 concurrent run, e.g.10.git_source: This functionality is in Public Preview. An optional specification for a remote repository containing the notebooks used by this job’s notebook tasks, e.g.
databricks_credentials: Credentials to use for authentication with Databricks.job_id: The canonical identifier of the job to delete. This field is required, e.g.11223344.
- Upon success, an empty dict.
API Endpoint:
/2.1/jobs/delete
API Responses:
| Response | Description |
|---|---|
| 200 | Job was deleted successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_get
job_id: The canonical identifier of the job to retrieve information about. This field is required.databricks_credentials: Credentials to use for authentication with Databricks.
- Upon success, a dict of the response.
job_id: intcreator_user_name: strrun_as_user_name: strsettings: "models.JobSettings"created_time: int
API Endpoint:
/2.1/jobs/get
API Responses:
| Response | Description |
|---|---|
| 200 | Job was retrieved successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_list
databricks_credentials: Credentials to use for authentication with Databricks.limit: The number of jobs to return. This value must be greater than 0 and less or equal to 25. The default value is 20.offset: The offset of the first job to return, relative to the most recently created job.name: A filter on the list based on the exact (case insensitive) job name.expand_tasks: Whether to include task and cluster details in the response.
- Upon success, a dict of the response.
jobs: List["models.Job"]has_more: bool
API Endpoint:
/2.1/jobs/list
API Responses:
| Response | Description |
|---|---|
| 200 | List of jobs was retrieved successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_reset
databricks_credentials: Credentials to use for authentication with Databricks.job_id: The canonical identifier of the job to reset. This field is required, e.g.11223344.new_settings: The new settings of the job. These settings completely replace the old settings. Changes to the fieldJobSettings.timeout_secondsare applied to active runs. Changes to other fields are applied to future runs only. Key-values:- name:
An optional name for the job, e.g.
A multitask job. - tags:
A map of tags associated with the job. These are forwarded
to the cluster as cluster tags for jobs clusters, and are
subject to the same limitations as cluster tags. A maximum
of 25 tags can be added to the job, e.g.
- tasks:
A list of task specifications to be executed by this job, e.g.
- job_clusters:
A list of job cluster specifications that can be shared and
reused by tasks of this job. Libraries cannot be declared in
a shared job cluster. You must declare dependent libraries
in task settings, e.g.
- email_notifications: An optional set of email addresses that is notified when runs of this job begin or complete as well as when this job is deleted. The default behavior is to not send any emails.
- webhook_notifications: A collection of system notification IDs to notify when runs of this job begin or complete. The default behavior is to not send any system notifications.
- timeout_seconds:
An optional timeout applied to each run of this job. The
default behavior is to have no timeout, e.g.
86400. - schedule:
An optional periodic schedule for this job. The default
behavior is that the job only runs when triggered by
clicking “Run Now” in the Jobs UI or sending an API request
to
runNow. - max_concurrent_runs:
An optional maximum allowed number of concurrent runs of the
job. Set this value if you want to be able to execute
multiple runs of the same job concurrently. This is useful
for example if you trigger your job on a frequent schedule
and want to allow consecutive runs to overlap with each
other, or if you want to trigger multiple runs which differ
by their input parameters. This setting affects only new
runs. For example, suppose the job’s concurrency is 4 and
there are 4 concurrent active runs. Then setting the
concurrency to 3 won’t kill any of the active runs. However,
from then on, new runs are skipped unless there are fewer
than 3 active runs. This value cannot exceed 1000. Setting
this value to 0 causes all new runs to be skipped. The
default behavior is to allow only 1 concurrent run, e.g.
10. - git_source:
This functionality is in Public Preview. An optional
specification for a remote repository containing the
notebooks used by this job’s notebook tasks, e.g.
- format:
Used to tell what is the format of the job. This field is
ignored in Create/Update/Reset calls. When using the Jobs
API 2.1 this value is always set to
'MULTI_TASK', e.g.MULTI_TASK. - job_settings: Job-level parameter definitions.
- Upon success, an empty dict.
API Endpoint:
/2.1/jobs/reset
API Responses:
| Response | Description |
|---|---|
| 200 | Job was overwritten successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_run_now
run_id of the triggered run.
Args:
databricks_credentials: Credentials to use for authentication with Databricks.job_id: The ID of the job to be executed, e.g.11223344.idempotency_token: An optional token to guarantee the idempotency of job run requests. If a run with the provided token already exists, the request does not create a new run but returns the ID of the existing run instead. If a run with the provided token is deleted, an error is returned. If you specify the idempotency token, upon failure you can retry until the request succeeds. Databricks guarantees that exactly one run is launched with that idempotency token. This token must have at most 64 characters. For more information, see [How to ensure idempotency for jobs](https://kb.databricks.com/jobs/jobs- idempotency.html), e.g.8f018174-4792-40d5-bcbc-3e6a527352c8.jar_params: A list of parameters for jobs with Spark JAR tasks, for example'jar_params'\: ['john doe', '35']. The parameters are used to invoke the main function of the main class specified in the Spark JAR task. If not specified uponrun-now, it defaults to an empty list. jar_params cannot be specified in conjunction with notebook_params. The JSON representation of this field (for example{'jar_params'\:['john doe','35']}) cannot exceed 10,000 bytes. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs, e.g.
notebook_params: A map from keys to values for jobs with notebook task, for example'notebook_params'\: {'name'\: 'john doe', 'age'\: '35'}. The map is passed to the notebook and is accessible through the [dbutils.widgets.get](https://docs.databricks.com/dev- tools/databricks-utils.html dbutils-widgets) function. If not specified uponrun-now, the triggered run uses the job’s base parameters. notebook_params cannot be specified in conjunction with jar_params. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs. The JSON representation of this field (for example{'notebook_params'\:{'name'\:'john doe','age'\:'35'}}) cannot exceed 10,000 bytes, e.g.
python_params: A list of parameters for jobs with Python tasks, for example'python_params'\: ['john doe', '35']. The parameters are passed to Python file as command-line parameters. If specified uponrun-now, it would overwrite the parameters specified in job setting. The JSON representation of this field (for example{'python_params'\:['john doe','35']}) cannot exceed 10,000 bytes. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs. Important These parameters accept only Latin characters (ASCII character set). Using non-ASCII characters returns an error. Examples of invalid, non-ASCII characters are Chinese, Japanese kanjis, and emojis, e.g.
spark_submit_params: A list of parameters for jobs with spark submit task, for example'spark_submit_params'\: ['--class', 'org.apache.spark.examples.SparkPi']. The parameters are passed to spark-submit script as command-line parameters. If specified uponrun-now, it would overwrite the parameters specified in job setting. The JSON representation of this field (for example{'python_params'\:['john doe','35']}) cannot exceed 10,000 bytes. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs. Important These parameters accept only Latin characters (ASCII character set). Using non-ASCII characters returns an error. Examples of invalid, non-ASCII characters are Chinese, Japanese kanjis, and emojis, e.g.
python_named_params: A map from keys to values for jobs with Python wheel task, for example'python_named_params'\: {'name'\: 'task', 'data'\: 'dbfs\:/path/to/data.json'}, e.g.
pipeline_params:sql_params: A map from keys to values for SQL tasks, for example'sql_params'\: {'name'\: 'john doe', 'age'\: '35'}. The SQL alert task does not support custom parameters, e.g.
dbt_commands: An array of commands to execute for jobs with the dbt task, for example'dbt_commands'\: ['dbt deps', 'dbt seed', 'dbt run'], e.g.
job_parameters: A map from keys to values for job-level parameters used in the run, for example'job_parameters'\: {'param'\: 'overriding_val'}, e.g.
- Upon success, a dict of the response.
run_id: intnumber_in_job: int
API Endpoint:
/2.1/jobs/run-now
API Responses:
| Response | Description |
|---|---|
| 200 | Run was started successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_cancel
databricks_credentials: Credentials to use for authentication with Databricks.run_id: This field is required, e.g.455644833.
- Upon success, an empty dict.
API Endpoint:
/2.1/jobs/runs/cancel
API Responses:
| Response | Description |
|---|---|
| 200 | Run was cancelled successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_cancel_all
databricks_credentials: Credentials to use for authentication with Databricks.job_id: The canonical identifier of the job to cancel all runs of. This field is required, e.g.11223344.
- Upon success, an empty dict.
API Endpoint:
/2.1/jobs/runs/cancel-all
API Responses:
| Response | Description |
|---|---|
| 200 | All runs were cancelled successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_delete
databricks_credentials: Credentials to use for authentication with Databricks.run_id: The canonical identifier of the run for which to retrieve the metadata, e.g.455644833.
- Upon success, an empty dict.
API Endpoint:
/2.1/jobs/runs/delete
API Responses:
| Response | Description |
|---|---|
| 200 | Run was deleted successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_get
run_id: The canonical identifier of the run for which to retrieve the metadata. This field is required.databricks_credentials: Credentials to use for authentication with Databricks.include_history: Whether to include the repair history in the response.
- Upon success, a dict of the response.
job_id: intrun_id: intnumber_in_job: intcreator_user_name: stroriginal_attempt_run_id: intstate: "models.RunState"schedule: "models.CronSchedule"tasks: List["models.RunTask"]job_clusters: List["models.JobCluster"]cluster_spec: "models.ClusterSpec"cluster_instance: "models.ClusterInstance"git_source: "models.GitSource"overriding_parameters: "models.RunParameters"start_time: intsetup_duration: intexecution_duration: intcleanup_duration: intend_time: inttrigger: "models.TriggerType"run_name: strrun_page_url: strrun_type: "models.RunType"attempt_number: intrepair_history: List["models.RepairHistoryItem"]job_parameters: List["models.RunJobParameter]"
API Endpoint:
/2.1/jobs/runs/get
API Responses:
| Response | Description |
|---|---|
| 200 | Run was retrieved successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_get_output
run_id: The canonical identifier for the run. This field is required.databricks_credentials: Credentials to use for authentication with Databricks.
- Upon success, a dict of the response.
notebook_output: "models.NotebookOutput"sql_output: "models.SqlOutput"dbt_output: "models.DbtOutput"logs: strlogs_truncated: boolerror: strerror_trace: strmetadata: "models.Run"
API Endpoint:
/2.1/jobs/runs/get-output
API Responses:
| Response | Description |
|---|---|
| 200 | Run output was retrieved successfully. |
| 400 | A job run with multiple tasks was provided. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_list
databricks_credentials: Credentials to use for authentication with Databricks.active_only: If active_only istrue, only active runs are included in the results; otherwise, lists both active and completed runs. An active run is a run in thePENDING,RUNNING, orTERMINATING. This field cannot betruewhen completed_only istrue.completed_only: If completed_only istrue, only completed runs are included in the results; otherwise, lists both active and completed runs. This field cannot betruewhen active_only istrue.job_id: The job for which to list runs. If omitted, the Jobs service lists runs from all jobs.offset: The offset of the first run to return, relative to the most recent run.limit: The number of runs to return. This value must be greater than 0 and less than 25. The default value is 25. If a request specifies a limit of 0, the service instead uses the maximum limit.run_type: The type of runs to return. For a description of run types, see [Run](https://docs.databricks.com/dev- tools/api/latest/jobs.html operation/JobsRunsGet).expand_tasks: Whether to include task and cluster details in the response.start_time_from: Show runs that started at or after this value. The value must be a UTC timestamp in milliseconds. Can be combined with start_time_to to filter by a time range.start_time_to: Show runs that started at or before this value. The value must be a UTC timestamp in milliseconds. Can be combined with start_time_from to filter by a time range.
- Upon success, a dict of the response.
runs: List["models.Run"]has_more: bool
API Endpoint:
/2.1/jobs/runs/list
API Responses:
| Response | Description |
|---|---|
| 200 | List of runs was retrieved successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_repair
databricks_credentials: Credentials to use for authentication with Databricks.run_id: The job run ID of the run to repair. The run must not be in progress, e.g.455644833.rerun_tasks: The task keys of the task runs to repair, e.g.
latest_repair_id: The ID of the latest repair. This parameter is not required when repairing a run for the first time, but must be provided on subsequent requests to repair the same run, e.g.734650698524280.rerun_all_failed_tasks: If true, repair all failed tasks. Only one of rerun_tasks or rerun_all_failed_tasks can be used.jar_params: A list of parameters for jobs with Spark JAR tasks, for example'jar_params'\: ['john doe', '35']. The parameters are used to invoke the main function of the main class specified in the Spark JAR task. If not specified uponrun-now, it defaults to an empty list. jar_params cannot be specified in conjunction with notebook_params. The JSON representation of this field (for example{'jar_params'\:['john doe','35']}) cannot exceed 10,000 bytes. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs, e.g.
notebook_params: A map from keys to values for jobs with notebook task, for example'notebook_params'\: {'name'\: 'john doe', 'age'\: '35'}. The map is passed to the notebook and is accessible through the [dbutils.widgets.get](https://docs.databricks.com/dev- tools/databricks-utils.html dbutils-widgets) function. If not specified uponrun-now, the triggered run uses the job’s base parameters. notebook_params cannot be specified in conjunction with jar_params. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs. The JSON representation of this field (for example{'notebook_params'\:{'name'\:'john doe','age'\:'35'}}) cannot exceed 10,000 bytes, e.g.
python_params: A list of parameters for jobs with Python tasks, for example'python_params'\: ['john doe', '35']. The parameters are passed to Python file as command-line parameters. If specified uponrun-now, it would overwrite the parameters specified in job setting. The JSON representation of this field (for example{'python_params'\:['john doe','35']}) cannot exceed 10,000 bytes. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs. Important These parameters accept only Latin characters (ASCII character set). Using non-ASCII characters returns an error. Examples of invalid, non-ASCII characters are Chinese, Japanese kanjis, and emojis, e.g.
spark_submit_params: A list of parameters for jobs with spark submit task, for example'spark_submit_params'\: ['--class', 'org.apache.spark.examples.SparkPi']. The parameters are passed to spark-submit script as command-line parameters. If specified uponrun-now, it would overwrite the parameters specified in job setting. The JSON representation of this field (for example{'python_params'\:['john doe','35']}) cannot exceed 10,000 bytes. Use [Task parameter variables](https://docs.databricks.com/jobs.html parameter-variables) to set parameters containing information about job runs. Important These parameters accept only Latin characters (ASCII character set). Using non-ASCII characters returns an error. Examples of invalid, non-ASCII characters are Chinese, Japanese kanjis, and emojis, e.g.
python_named_params: A map from keys to values for jobs with Python wheel task, for example'python_named_params'\: {'name'\: 'task', 'data'\: 'dbfs\:/path/to/data.json'}, e.g.
pipeline_params:sql_params: A map from keys to values for SQL tasks, for example'sql_params'\: {'name'\: 'john doe', 'age'\: '35'}. The SQL alert task does not support custom parameters, e.g.
dbt_commands: An array of commands to execute for jobs with the dbt task, for example'dbt_commands'\: ['dbt deps', 'dbt seed', 'dbt run'], e.g.
job_parameters: A map from keys to values for job-level parameters used in the run, for example'job_parameters'\: {'param'\: 'overriding_val'}, e.g.
- Upon success, a dict of the response.
repair_id: int
API Endpoint:
/2.1/jobs/runs/repair
API Responses:
| Response | Description |
|---|---|
| 200 | Run repair was initiated. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |
jobs_runs_submit
jobs/runs/get API to check the run state
after the job is submitted.
Args:
databricks_credentials: Credentials to use for authentication with Databricks.tasks: , e.g.
run_name: An optional name for the run. The default value isUntitled, e.g.A multitask job run.webhook_notifications: A collection of system notification IDs to notify when runs of this job begin or complete. The default behavior is to not send any system notifications. Key-values:- on_start:
An optional list of notification IDs to call when the run
starts. A maximum of 3 destinations can be specified for the
on_startproperty, e.g. - on_success:
An optional list of notification IDs to call when the run
completes successfully. A maximum of 3 destinations can be
specified for the
on_successproperty, e.g. - on_failure:
An optional list of notification IDs to call when the run
fails. A maximum of 3 destinations can be specified for the
on_failureproperty, e.g. git_source: This functionality is in Public Preview. An optional specification for a remote repository containing the notebooks used by this job’s notebook tasks, e.g.
databricks_credentials: Credentials to use for authentication with Databricks.job_id: The canonical identifier of the job to update. This field is required, e.g.11223344.new_settings: The new settings for the job. Any top-level fields specified innew_settingsare completely replaced. Partially updating nested fields is not supported. Changes to the fieldJobSettings.timeout_secondsare applied to active runs. Changes to other fields are applied to future runs only. Key-values:- name:
An optional name for the job, e.g.
A multitask job. - tags:
A map of tags associated with the job. These are forwarded
to the cluster as cluster tags for jobs clusters, and are
subject to the same limitations as cluster tags. A maximum
of 25 tags can be added to the job, e.g.
- tasks:
A list of task specifications to be executed by this job, e.g.
- job_clusters:
A list of job cluster specifications that can be shared and
reused by tasks of this job. Libraries cannot be declared in
a shared job cluster. You must declare dependent libraries
in task settings, e.g.
- email_notifications: An optional set of email addresses that is notified when runs of this job begin or complete as well as when this job is deleted. The default behavior is to not send any emails.
- webhook_notifications: A collection of system notification IDs to notify when runs of this job begin or complete. The default behavior is to not send any system notifications.
- timeout_seconds:
An optional timeout applied to each run of this job. The
default behavior is to have no timeout, e.g.
86400. - schedule:
An optional periodic schedule for this job. The default
behavior is that the job only runs when triggered by
clicking “Run Now” in the Jobs UI or sending an API request
to
runNow. - max_concurrent_runs:
An optional maximum allowed number of concurrent runs of the
job. Set this value if you want to be able to execute
multiple runs of the same job concurrently. This is useful
for example if you trigger your job on a frequent schedule
and want to allow consecutive runs to overlap with each
other, or if you want to trigger multiple runs which differ
by their input parameters. This setting affects only new
runs. For example, suppose the job’s concurrency is 4 and
there are 4 concurrent active runs. Then setting the
concurrency to 3 won’t kill any of the active runs. However,
from then on, new runs are skipped unless there are fewer
than 3 active runs. This value cannot exceed 1000. Setting
this value to 0 causes all new runs to be skipped. The
default behavior is to allow only 1 concurrent run, e.g.
10. - git_source:
This functionality is in Public Preview. An optional
specification for a remote repository containing the
notebooks used by this job’s notebook tasks, e.g.
- format:
Used to tell what is the format of the job. This field is
ignored in Create/Update/Reset calls. When using the Jobs
API 2.1 this value is always set to
'MULTI_TASK', e.g.MULTI_TASK. - parameters: Job-level parameter definitions.
fields_to_remove: Remove top-level fields in the job settings. Removing nested fields is not supported. This field is optional, e.g.
- Upon success, an empty dict.
API Endpoint:
/2.1/jobs/update
API Responses:
| Response | Description |
|---|---|
| 200 | Job was updated successfully. |
| 400 | The request was malformed. See JSON response for error details. |
| 401 | The request was unauthorized. |
| 500 | The request was not handled correctly due to a server error. |