Databricks Jobs: Setting Job Properties Through Scripts

Attributes defined for an object affect how the object is processed. Script statements allow you to dynamically change those object attributes and assign new values when the task is generated. The new values are only valid for the current generation and are not permanently stored in the object.

You can define the values of any of the settings of all Databricks Jobs using scripts. You do this by using :PUT_ATT commands on the Pre-Process object definition page.

For more information, see the Automic Automation product documentation:

This page includes the following:

Databricks Run Job Parameters

The attributes available for Databricks Run Jobs are the following:

  • connection

    Defines the Connection object that has the details to connect with Databricks.

    Value: text

  • executionType

    Defines the type of execution to run a job which is available for the user.

    Value: Run now, Run submit

    • Run now (default)
      Runs the job.

    • Run submit
      Submits a one-time run of the job. It creates a job if it does not yet exist, or updates the existing one.

  • runNowInputType

    Defines if the user can use the Job ID without parameters or Job ID with parameters.

    Values: Job id without parameters (default), Job id with parameters

  • jobId

    Defines the Job ID if the user selects the Job ID without parameters as the Run Now Input Type.

    Value: Job ID

  • runNowJson
    Defines a job with a Databricks Run Now JSON payload if the user selects Job ID with parameters.

    Value: JSON

  • runSubmitJson
    Defines the Databricks Runs Submit JSON payload if the user submits a one-time run.

    Value: JSON

Example

The following example shows how you can use :PUT_ATT:

Databricks Start Or Stop Cluster Job Parameters

The attributes available for Databricks Start Or Stop Cluster Jobs are the following:

  • connection

    Defines the value of the Databricks Connection object

    Value: text

  • operationType

    Defines the type of operation to start or stop the cluster on Databricks.

    Values: Start (default), Stop

    • Start
      Starts the cluster

    • Stop
      Stops the cluster

  • clusterId

    Defines the Cluster ID.

    Value: Cluster ID

See also: