public class Task extends AbstractModel
Constructor and Description |
---|
Task() |
Task(Task source)
NOTE: Any ambiguous key set via .set("AnyKey", "value") will be a shallow copy,
and any explicit key, i.e Foo, set via .setFoo("value") will be a deep copy.
|
Modifier and Type | Method and Description |
---|---|
Application |
getApplication()
Get Application information
|
Authentication[] |
getAuthentications()
Get Authorization information
|
AnonymousComputeEnv |
getComputeEnv()
Get Compute environment information.
|
String |
getEnvId()
Get Compute environment ID.
|
EnvVar[] |
getEnvVars()
Get Custom environment variable
|
String |
getFailedAction()
Get The processing method after the TaskInstance fails; Value range: `TERMINATE` (default), `INTERRUPT`, `FAST_INTERRUPT`.
|
InputMapping[] |
getInputMappings()
Get Input mapping
|
Long |
getMaxConcurrentNum()
Get The maximum number of concurrent tasks.
|
Long |
getMaxRetryCount()
Get The maximum number of retries after the task fails.
|
OutputMappingConfig[] |
getOutputMappingConfigs()
Get Output mapping configuration
|
OutputMapping[] |
getOutputMappings()
Get Output mapping
|
RedirectInfo |
getRedirectInfo()
Get Redirection information
|
RedirectLocalInfo |
getRedirectLocalInfo()
Get Local redirection information
|
Long |
getResourceMaxRetryCount()
Get Maximum number of retry attempts after failing to create computing resources such as the CVM in the task launch process.
|
Boolean |
getRestartComputeNode()
Get Restarts the compute node after the task is completed.
|
Long |
getTaskInstanceNum()
Get Number of running task instances
|
String |
getTaskName()
Get Task name, which should be unique within a job
|
Long |
getTimeout()
Get Timeout period of the task in seconds.
|
void |
setApplication(Application Application)
Set Application information
|
void |
setAuthentications(Authentication[] Authentications)
Set Authorization information
|
void |
setComputeEnv(AnonymousComputeEnv ComputeEnv)
Set Compute environment information.
|
void |
setEnvId(String EnvId)
Set Compute environment ID.
|
void |
setEnvVars(EnvVar[] EnvVars)
Set Custom environment variable
|
void |
setFailedAction(String FailedAction)
Set The processing method after the TaskInstance fails; Value range: `TERMINATE` (default), `INTERRUPT`, `FAST_INTERRUPT`.
|
void |
setInputMappings(InputMapping[] InputMappings)
Set Input mapping
|
void |
setMaxConcurrentNum(Long MaxConcurrentNum)
Set The maximum number of concurrent tasks.
|
void |
setMaxRetryCount(Long MaxRetryCount)
Set The maximum number of retries after the task fails.
|
void |
setOutputMappingConfigs(OutputMappingConfig[] OutputMappingConfigs)
Set Output mapping configuration
|
void |
setOutputMappings(OutputMapping[] OutputMappings)
Set Output mapping
|
void |
setRedirectInfo(RedirectInfo RedirectInfo)
Set Redirection information
|
void |
setRedirectLocalInfo(RedirectLocalInfo RedirectLocalInfo)
Set Local redirection information
|
void |
setResourceMaxRetryCount(Long ResourceMaxRetryCount)
Set Maximum number of retry attempts after failing to create computing resources such as the CVM in the task launch process.
|
void |
setRestartComputeNode(Boolean RestartComputeNode)
Set Restarts the compute node after the task is completed.
|
void |
setTaskInstanceNum(Long TaskInstanceNum)
Set Number of running task instances
|
void |
setTaskName(String TaskName)
Set Task name, which should be unique within a job
|
void |
setTimeout(Long Timeout)
Set Timeout period of the task in seconds.
|
void |
toMap(HashMap<String,String> map,
String prefix)
Internal implementation, normal users should not use it.
|
any, fromJsonString, getBinaryParams, getMultipartRequestParams, set, setParamArrayObj, setParamArraySimple, setParamObj, setParamSimple, toJsonString
public Task()
public Task(Task source)
public Application getApplication()
public void setApplication(Application Application)
Application
- Application informationpublic String getTaskName()
public void setTaskName(String TaskName)
TaskName
- Task name, which should be unique within a jobpublic Long getTaskInstanceNum()
public void setTaskInstanceNum(Long TaskInstanceNum)
TaskInstanceNum
- Number of running task instancespublic AnonymousComputeEnv getComputeEnv()
public void setComputeEnv(AnonymousComputeEnv ComputeEnv)
ComputeEnv
- Compute environment information. One (and only one) parameter must be specified for ComputeEnv and EnvId.public String getEnvId()
public void setEnvId(String EnvId)
EnvId
- Compute environment ID. One (and only one) parameter must be specified for ComputeEnv and EnvId.public RedirectInfo getRedirectInfo()
public void setRedirectInfo(RedirectInfo RedirectInfo)
RedirectInfo
- Redirection informationpublic RedirectLocalInfo getRedirectLocalInfo()
public void setRedirectLocalInfo(RedirectLocalInfo RedirectLocalInfo)
RedirectLocalInfo
- Local redirection informationpublic InputMapping[] getInputMappings()
public void setInputMappings(InputMapping[] InputMappings)
InputMappings
- Input mappingpublic OutputMapping[] getOutputMappings()
public void setOutputMappings(OutputMapping[] OutputMappings)
OutputMappings
- Output mappingpublic OutputMappingConfig[] getOutputMappingConfigs()
public void setOutputMappingConfigs(OutputMappingConfig[] OutputMappingConfigs)
OutputMappingConfigs
- Output mapping configurationpublic EnvVar[] getEnvVars()
public void setEnvVars(EnvVar[] EnvVars)
EnvVars
- Custom environment variablepublic Authentication[] getAuthentications()
public void setAuthentications(Authentication[] Authentications)
Authentications
- Authorization informationpublic String getFailedAction()
public void setFailedAction(String FailedAction)
FailedAction
- The processing method after the TaskInstance fails; Value range: `TERMINATE` (default), `INTERRUPT`, `FAST_INTERRUPT`.public Long getMaxRetryCount()
public void setMaxRetryCount(Long MaxRetryCount)
MaxRetryCount
- The maximum number of retries after the task fails. Range: 0 - 5. Default value: 0public Long getTimeout()
public void setTimeout(Long Timeout)
Timeout
- Timeout period of the task in seconds. Defaults value: 86400public Long getMaxConcurrentNum()
public void setMaxConcurrentNum(Long MaxConcurrentNum)
MaxConcurrentNum
- The maximum number of concurrent tasks. Range: 0 - 200000. There is no limit by default.public Boolean getRestartComputeNode()
public void setRestartComputeNode(Boolean RestartComputeNode)
RestartComputeNode
- Restarts the compute node after the task is completed. This is suitable for specifying the compute environment for task execution.public Long getResourceMaxRetryCount()
public void setResourceMaxRetryCount(Long ResourceMaxRetryCount)
ResourceMaxRetryCount
- Maximum number of retry attempts after failing to create computing resources such as the CVM in the task launch process. Default: `0`; Maximum: `100`.Copyright © 2023. All rights reserved.