Submits a Spark job.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes SubmitSparkJob

The operation that you want to perform. Set the value to SubmitSparkJob.

ConfigJson String Yes { "name": "SparkPi", "file": "local:///tmp/spark-examples.jar", "className": "org.apache.spark.examples.SparkPi", "args": [ "100" ], "conf": { "spark.driver.resourceSpec": "medium", "spark.executor.instances": 5, "spark.executor.resourceSpec": "medium" } }

The JSON string that defines the Spark job.

VcName String Yes MyCluster

The name of the virtual cluster (VC) on which the job is executed.

Response parameters

Parameter Type Example Description
JobId String j202011032013hangzhouf742a4330003679

The ID of the Spark job.

RequestId String C039FD4D-2F3C-4556-AF09-864D3A6485B2

The unique ID of the request.


Sample requests

http(s)://[Endpoint]/? Action=SubmitSparkJob
&ConfigJson={     "name": "SparkPi",     "file": "local:///tmp/spark-examples.jar",     "className": "org.apache.spark.examples.SparkPi",     "args": [         "100"     ],     "conf": {         "spark.driver.resourceSpec": "medium",         "spark.executor.instances": 5,         "spark.executor.resourceSpec": "medium"     } }
&<Common request parameters>

Sample success responses

XML format


JSON format

  "RequestId": "C039FD4D-2F3C-4556-AF09-864D3A6485B2",
  "JobId": "j202011032013hangzhouf742a4330003679"

Error codes

For a list of error codes, visit the API Error Center.