Share via


Spark Session - Get Spark Sessions

Liste todas as sessões do Spark em execução em um pool específico do Spark.

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

Parâmetros de URI

Nome Em Obrigatório Tipo Description
endpoint
path True

string

O ponto de extremidade de desenvolvimento do workspace, por exemplo https://myworkspace.dev.azuresynapse.net.

livyApiVersion
path True

string

Versão de API válida para a solicitação.

sparkPoolName
path True

string

Nome do pool do Spark.

detailed
query

boolean

Parâmetro de consulta opcional que especifica se a resposta detalhada é retornada além do livy simples.

from
query

integer

int32

Parâmetro opcional que especifica de qual índice a lista deve começar.

size
query

integer

int32

Parâmetro opcional que especifica o tamanho da lista retornada.

        By default it is 20 and that is the maximum.

Respostas

Nome Tipo Description
200 OK

SparkSessionCollection

Êxito

Exemplos

List all spark session jobs

Sample Request

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

Sample Response

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

Definições

Nome Description
LivyStates

O estado do lote

PluginCurrentState
SchedulerCurrentState
SparkErrorSource
SparkJobType

O tipo de trabalho.

SparkRequest
SparkScheduler
SparkServiceError
SparkServicePlugin
SparkSession
SparkSessionCollection
SparkSessionResultType
SparkSessionState

LivyStates

O estado do lote

Nome Tipo Description
busy

string

dead

string

error

string

idle

string

killed

string

not_started

string

recovering

string

running

string

shutting_down

string

starting

string

success

string

PluginCurrentState

Nome Tipo Description
Cleanup

string

Ended

string

Monitoring

string

Preparation

string

Queued

string

ResourceAcquisition

string

Submission

string

SchedulerCurrentState

Nome Tipo Description
Ended

string

Queued

string

Scheduled

string

SparkErrorSource

Nome Tipo Description
Dependency

string

System

string

Unknown

string

User

string

SparkJobType

O tipo de trabalho.

Nome Tipo Description
SparkBatch

string

SparkSession

string

SparkRequest

Nome Tipo Description
archives

string[]

args

string[]

className

string

conf

object

driverCores

integer

driverMemory

string

executorCores

integer

executorMemory

string

file

string

files

string[]

jars

string[]

name

string

numExecutors

integer

pyFiles

string[]

SparkScheduler

Nome Tipo Description
cancellationRequestedAt

string

currentState

SchedulerCurrentState

endedAt

string

scheduledAt

string

submittedAt

string

SparkServiceError

Nome Tipo Description
errorCode

string

message

string

source

SparkErrorSource

SparkServicePlugin

Nome Tipo Description
cleanupStartedAt

string

currentState

PluginCurrentState

monitoringStartedAt

string

preparationStartedAt

string

resourceAcquisitionStartedAt

string

submissionStartedAt

string

SparkSession

Nome Tipo Description
appId

string

appInfo

object

artifactId

string

errorInfo

SparkServiceError[]

id

integer

jobType

SparkJobType

livyInfo

SparkSessionState

log

string[]

name

string

pluginInfo

SparkServicePlugin

result

SparkSessionResultType

schedulerInfo

SparkScheduler

sparkPoolName

string

state

LivyStates

O estado da sessão.

submitterId

string

submitterName

string

tags

object

workspaceName

string

SparkSessionCollection

Nome Tipo Description
from

integer

sessions

SparkSession[]

total

integer

SparkSessionResultType

Nome Tipo Description
Cancelled

string

Failed

string

Succeeded

string

Uncertain

string

SparkSessionState

Nome Tipo Description
busyAt

string

currentState

string

deadAt

string

errorAt

string

idleAt

string

jobCreationRequest

SparkRequest

killedAt

string

notStartedAt

string

recoveringAt

string

shuttingDownAt

string

startingAt

string