Delen via


Spark Batch - Get Spark Batch Jobs

Vermeld alle Spark-batchtaken die worden uitgevoerd onder een bepaalde Spark-pool.

GET {endpoint}/livyApi/versions/{livyApiVersion}/sparkPools/{sparkPoolName}/batches
GET {endpoint}/livyApi/versions/{livyApiVersion}/sparkPools/{sparkPoolName}/batches?from={from}&size={size}&detailed={detailed}

URI-parameters

Name In Vereist Type Description
endpoint
path True

string

Het eindpunt voor werkruimteontwikkeling, bijvoorbeeld https://myworkspace.dev.azuresynapse.net.

livyApiVersion
path True

string

Geldige API-versie voor de aanvraag.

sparkPoolName
path True

string

Naam van de spark-pool.

detailed
query

boolean

Optionele queryparameter die aangeeft of een gedetailleerd antwoord wordt geretourneerd buiten gewone livy.

from
query

integer (int32)

Optionele param die aangeeft vanaf welke index de lijst moet beginnen.

size
query

integer (int32)

Optionele param die de grootte van de geretourneerde lijst aangeeft.

        By default it is 20 and that is the maximum.

Antwoorden

Name Type Description
200 OK

SparkBatchJobCollection

Geslaagd

Voorbeelden

List all spark batch jobs

Voorbeeldaanvraag

GET myWorkspace.dev.azuresynapse.net/livyApi/versions/2020-12-01/sparkPools/mySparkPool/batches?from=0&size=2&detailed=True

Voorbeeldrespons

{
  "from": 0,
  "total": 2,
  "sessions": []
}

Definities

Name Description
LivyStates

De batchstatus

PluginCurrentState
SchedulerCurrentState
SparkBatchJob
SparkBatchJobCollection

Antwoord voor batchlijstbewerking.

SparkBatchJobResultType

Het resultaat van de Spark-batchtaak.

SparkBatchJobState
SparkErrorSource
SparkJobType

Het taaktype.

SparkRequest
SparkScheduler
SparkServiceError
SparkServicePlugin

LivyStates

De batchstatus

Waarde Description
busy
dead
error
idle
killed
not_started
recovering
running
shutting_down
starting
success

PluginCurrentState

Waarde Description
Cleanup
Ended
Monitoring
Preparation
Queued
ResourceAcquisition
Submission

SchedulerCurrentState

Waarde Description
Ended
Queued
Scheduled

SparkBatchJob

Name Type Description
appId

string

De toepassings-id van deze sessie

appInfo

object

De gedetailleerde toepassingsgegevens.

artifactId

string

De artefact-id.

errorInfo

SparkServiceError[]

De foutinformatie.

id

integer (int32)

De sessie-id.

jobType

SparkJobType

Het taaktype.

livyInfo

SparkBatchJobState

log

string[]

De logboeklijnen.

name

string

De batchnaam.

pluginInfo

SparkServicePlugin

De informatie van de invoegtoepassing.

result

SparkBatchJobResultType

Het resultaat van de Spark-batchtaak.

schedulerInfo

SparkScheduler

De scheduler-informatie.

sparkPoolName

string

De naam van de Spark-pool.

state

LivyStates

De batchstatus

submitterId

string

De verzender-id.

submitterName

string

De naam van de inzender.

tags

object

De tags.

workspaceName

string

De naam van de werkruimte.

SparkBatchJobCollection

Antwoord voor batchlijstbewerking.

Name Type Description
from

integer (int32)

De startindex van opgehaalde sessies.

sessions

SparkBatchJob[]

Batch-lijst

total

integer (int32)

Aantal opgehaalde sessies.

SparkBatchJobResultType

Het resultaat van de Spark-batchtaak.

Waarde Description
Cancelled
Failed
Succeeded
Uncertain

SparkBatchJobState

Name Type Description
currentState

string

de status van de Spark-taak.

deadAt

string (date-time)

toen de "dode" livy-staat voor het eerst werd gezien.

jobCreationRequest

SparkRequest

killedAt

string (date-time)

het tijdstip waarop "vermoorde" Livy-staat voor het eerst werd gezien.

notStartedAt

string (date-time)

toen "not_started" livy-toestand voor het eerst werd gezien.

recoveringAt

string (date-time)

de tijd waarop "herstellende" Livy-toestand voor het eerst werd gezien.

runningAt

string (date-time)

het tijdstip waarop de livy-status 'actief' voor het eerst werd gezien.

startingAt

string (date-time)

het tijdstip waarop de livy-toestand 'starten' voor het eerst werd gezien.

successAt

string (date-time)

het tijdstip waarop "success" livy staat voor het eerst werd gezien.

SparkErrorSource

Waarde Description
Dependency
System
Unknown
User

SparkJobType

Het taaktype.

Waarde Description
SparkBatch
SparkSession

SparkRequest

Name Type Description
archives

string[]

args

string[]

className

string

conf

object

driverCores

integer (int32)

driverMemory

string

executorCores

integer (int32)

executorMemory

string

file

string

files

string[]

jars

string[]

name

string

numExecutors

integer (int32)

pyFiles

string[]

SparkScheduler

Name Type Description
cancellationRequestedAt

string (date-time)

currentState

SchedulerCurrentState

endedAt

string (date-time)

scheduledAt

string (date-time)

submittedAt

string (date-time)

SparkServiceError

Name Type Description
errorCode

string

message

string

source

SparkErrorSource

SparkServicePlugin

Name Type Description
cleanupStartedAt

string (date-time)

currentState

PluginCurrentState

monitoringStartedAt

string (date-time)

preparationStartedAt

string (date-time)

resourceAcquisitionStartedAt

string (date-time)

submissionStartedAt

string (date-time)