/create/job

URL: http://GPUDB_IP_ADDRESS:GPUDB_PORT/create/job

Create a job which will run asynchronously. The response returns a job ID, which can be used to query the status and result of the job. The status and the result of the job upon completion can be requested by /get/job.

Input Parameter Description

NameTypeDescription
endpointstringIndicates which endpoint to execute, e.g. '/alter/table'.
request_encodingstring

The encoding of the request payload for the job. The default value is binary. The supported values are:

  • binary
  • json
  • snappy
databytesBinary-encoded payload for the job to be run asynchronously. The payload must contain the relevant input parameters for the endpoint indicated in input parameter endpoint. Please see the documentation for the appropriate endpoint to see what values must (or can) be specified. If this parameter is used, then input parameter request_encoding must be binary or snappy.
data_strstringJSON-encoded payload for the job to be run asynchronously. The payload must contain the relevant input parameters for the endpoint indicated in input parameter endpoint. Please see the documentation for the appropriate endpoint to see what values must (or can) be specified. If this parameter is used, then input parameter request_encoding must be json.
optionsmap of string to strings

Optional parameters. The default value is an empty map ( {} ).

Supported Parameters (keys)Parameter Description
remove_job_on_complete

The supported values are:

  • true
  • false
job_tagTag to use for submitted job. The same tag could be used on backup cluster to retrieve response for the job. Tags can use letter, numbers, '_' and '-'

Output Parameter Description

The GPUdb server embeds the endpoint response inside a standard response structure which contains status information and the actual response to the query. Here is a description of the various fields of the wrapper:

NameTypeDescription
statusString'OK' or 'ERROR'
messageStringEmpty if success or an error message
data_typeString'create_job_request' or 'none' in case of an error
dataStringEmpty string
data_strJSON or String

This embedded JSON represents the result of the /create/job endpoint:

NameTypeDescription
job_idlongAn identifier for the job created by this call.
infomap of string to strings

Additional information. The default value is an empty map ( {} ).

Possible Parameters (keys)Parameter Description
job_tagThe job tag specified by the user or if unspecified by user, a unique identifier generated internally for the job across clusters.

Empty string in case of an error.