Syncplicity Support

Search our knowledgebase to get the help you need, today

Follow

Create job - configure started, paused status

DataHub allows, through REST configuration, the ability to create jobs with a predefined start-status. We can create jobs with manual schedules that execute immediately and auto schedules that are paused until the user intervenes. We have two options for this setting, based upon the chosen schedule method

  • start
  • paused

Job JSON Example

started 

  • In the DataHub Platform user-interface, started status corresponds to the "Save and Run Job" option for manual jobs
  • This will automatically start jobs with a manual schedule
  • After initial execution, the manual schedule will continue to be preserved

"status": "started"

{
    "name": "Start Job - Manual - As started",
    "kind": "transfer",
    "transfer": {
        "audit_level": "trace",
        "transfer_type": "copy",
        "source": {
            "connection": {
                "id": "{{cloud_connection_source}}"
            },
            "target": {
                "path": "/sourcePath"
            }
        },
        "destination": {
            "connection": {
                "id": "{{cloud_connection_destination}}"
            },
            "target": {
                "path": "/destinationPath"
            }
        }
    },
    "schedule": {
        "mode": "manual"
    },
    "status": "start"
}

paused

  • In the DataHub Platform user-interface, started status corresponds to the "Start as Paused" for auto schedule
  • This will pause the initial execution of the job until it is manually triggered by the user. Subsequent runs will continue on the normal specified schedule
  • The paused option is not preserved when making changes to the schedule. Should preservation be desired, each change will require this option

Note: When a job schedule of manual is configured, "paused" is not a valid option; only "start"

  • A manual job does not have a true schedule

"status": "paused"

{
    "name": "Start Job - Auto- As paused",
    "kind": "transfer",
    "transfer": {
        "audit_level": "trace",
        "transfer_type": "copy",
        "source": {
            "connection": {
                "id": "{{cloud_connection_source}}"
            },
            "target": {
                "path": "/sourcePath"
            }
        },
        "destination": {
            "connection": {
                "id": "{{cloud_connection_destination}}"
            },
            "target": {
                "path": "/destinationPath"
            }
        }
    },
    "schedule": {
        "mode": "auto"
    },
    "status": "paused"
}

PATCH / Modify Job

The start/paused settings can also be applied to existing jobs using the PATCH options available through the REST API. 

JSON Example

PATCH an existing job when changing the schedule

PATCH v1/jobs/<job-id>

{
    "kind": "transfer",
    "schedule": {
        "mode": "auto/manual"
    },
    "status": "paused/start"
}

Powered by Zendesk