github.com/chnsz/golangsdk@v0.0.0-20240506093406-85a3fbfa605b/openstack/dli/v2/batches/results.go (about) 1 package batches 2 3 const ( 4 // StateStarting is a state means the batch processing job is being started. 5 StateStarting = "starting" 6 // StateRunning is a state means the batch processing job is executing a task. 7 StateRunning = "running" 8 // StateDead is a state means the batch processing job has failed to execute. 9 StateDead = "dead" 10 // StateSuccess is a state means the batch processing job is successfully executed. 11 StateSuccess = "success" 12 // StateRecovering is a state means the batch processing job is being restored. 13 StateRecovering = "recovering" 14 ) 15 16 // CreateResp represents a result of the Create method. 17 type CreateResp struct { 18 // ID of a batch processing job. 19 ID string `json:"id"` 20 // Back-end application ID of a batch processing job. 21 AppId []string `json:"appId"` 22 // Name of a batch processing job. 23 Name string `json:"name"` 24 // Owner of a batch processing job. 25 Owner string `json:"owner"` 26 // Proxy user (resource tenant) to which a batch processing job belongs. 27 ProxyUser string `json:"proxyUser"` 28 // Status of a batch processing job. For details, see Table 7 in Creating a Batch Processing Job. 29 State string `json:"state"` 30 // Type of a batch processing job. Only Spark parameters are supported. 31 Kind string `json:"kind"` 32 // Last 10 records of the current batch processing job. 33 Log []string `json:"log"` 34 // Type of a computing resource. If the computing resource type is customized, value CUSTOMIZED is returned. 35 ScType string `json:"sc_type"` 36 // Queue where a batch processing job is located. 37 ClusterName string `json:"cluster_name"` 38 // Queue where a batch processing job is located. 39 Queue string `json:"queue"` 40 // Time when a batch processing job is created. The timestamp is expressed in milliseconds. 41 CreateTime int `json:"create_time"` 42 // Time when a batch processing job is updated. The timestamp is expressed in milliseconds. 43 UpdateTime int `json:"update_time"` 44 // Job feature. Type of the Spark image used by a job. 45 // basic: indicates that the basic Spark image provided by DLI is used. 46 // custom: indicates that the user-defined Spark image is used. 47 // ai: indicates that the AI image provided by DLI is used. 48 Feature string `json:"feature"` 49 // Version of the Spark component used by a job. Set this parameter when feature is set to basic or ai. 50 // If this parameter is not set, the default Spark component version 2.3.2 is used. 51 SparkVersion string `json:"spark_version"` 52 // Custom image. The format is Organization name/Image name:Image version. 53 // This parameter is valid only when feature is set to custom. You can use this parameter with the feature parameter 54 // to specify a user-defined Spark image for job running. For details about how to use custom images, see the Data 55 // Lake Insight User Guide. 56 Image string `json:"image"` 57 } 58 59 // StateResp represents a result of the GetState method. 60 type StateResp struct { 61 // ID of a batch processing job, which is in the universal unique identifier (UUID) format. 62 ID string `json:"id"` 63 // Status of a batch processing job. 64 // The valid values are starting, running, dead, success and recovering. For detail, see Constant definition. 65 State string `json:"state"` 66 }