ComputeTask

class oci.batch.models.ComputeTask(**kwargs)

Bases: oci.batch.models.batch_task.BatchTask

compute task represents a single executable command together with its dependencies and resources.

Attributes

LIFECYCLE_STATE_ACCEPTED str(object=’’) -> str
LIFECYCLE_STATE_CANCELED str(object=’’) -> str
LIFECYCLE_STATE_CANCELING str(object=’’) -> str
LIFECYCLE_STATE_FAILED str(object=’’) -> str
LIFECYCLE_STATE_IN_PROGRESS str(object=’’) -> str
LIFECYCLE_STATE_SUCCEEDED str(object=’’) -> str
LIFECYCLE_STATE_WAITING str(object=’’) -> str
TYPE_COMPUTE str(object=’’) -> str
arguments Gets the arguments of this ComputeTask.
batch_task_environment_id [Required] Gets the batch_task_environment_id of this ComputeTask.
batch_task_profile_id Gets the batch_task_profile_id of this ComputeTask.
command Gets the command of this ComputeTask.
dependencies [Required] Gets the dependencies of this BatchTask.
description Gets the description of this BatchTask.
entitlement_claims [Required] Gets the entitlement_claims of this BatchTask.
environment_variables [Required] Gets the environment_variables of this BatchTask.
fleet_assignment_policy Gets the fleet_assignment_policy of this ComputeTask.
id [Required] Gets the id of this BatchTask.
lifecycle_details Gets the lifecycle_details of this BatchTask.
lifecycle_state Gets the lifecycle_state of this BatchTask.
name [Required] Gets the name of this BatchTask.
type [Required] Gets the type of this BatchTask.

Methods

__init__(**kwargs) Initializes a new ComputeTask object with values from keyword arguments.
get_subtype(object_dictionary) Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.
LIFECYCLE_STATE_ACCEPTED = 'ACCEPTED'
LIFECYCLE_STATE_CANCELED = 'CANCELED'
LIFECYCLE_STATE_CANCELING = 'CANCELING'
LIFECYCLE_STATE_FAILED = 'FAILED'
LIFECYCLE_STATE_IN_PROGRESS = 'IN_PROGRESS'
LIFECYCLE_STATE_SUCCEEDED = 'SUCCEEDED'
LIFECYCLE_STATE_WAITING = 'WAITING'
TYPE_COMPUTE = 'COMPUTE'
__init__(**kwargs)

Initializes a new ComputeTask object with values from keyword arguments. The default value of the type attribute of this class is COMPUTE and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class):

Parameters:
  • id (str) – The value to assign to the id property of this ComputeTask.
  • name (str) – The value to assign to the name property of this ComputeTask.
  • description (str) – The value to assign to the description property of this ComputeTask.
  • type (str) – The value to assign to the type property of this ComputeTask. Allowed values for this property are: “COMPUTE”
  • lifecycle_state (str) – The value to assign to the lifecycle_state property of this ComputeTask. Allowed values for this property are: “ACCEPTED”, “WAITING”, “IN_PROGRESS”, “SUCCEEDED”, “FAILED”, “CANCELING”, “CANCELED”
  • lifecycle_details (str) – The value to assign to the lifecycle_details property of this ComputeTask.
  • entitlement_claims (list[str]) – The value to assign to the entitlement_claims property of this ComputeTask.
  • dependencies (list[str]) – The value to assign to the dependencies property of this ComputeTask.
  • environment_variables (list[oci.batch.models.EnvironmentVariable]) – The value to assign to the environment_variables property of this ComputeTask.
  • batch_task_profile_id (str) – The value to assign to the batch_task_profile_id property of this ComputeTask.
  • command (list[str]) – The value to assign to the command property of this ComputeTask.
  • arguments (list[str]) – The value to assign to the arguments property of this ComputeTask.
  • fleet_assignment_policy (oci.batch.models.FleetAssignmentPolicy) – The value to assign to the fleet_assignment_policy property of this ComputeTask.
  • batch_task_environment_id (str) – The value to assign to the batch_task_environment_id property of this ComputeTask.
arguments

Gets the arguments of this ComputeTask. Task arguments.

Returns:The arguments of this ComputeTask.
Return type:list[str]
batch_task_environment_id

[Required] Gets the batch_task_environment_id of this ComputeTask. The OCID of the BatchTaskEnvironment.

Returns:The batch_task_environment_id of this ComputeTask.
Return type:str
batch_task_profile_id

Gets the batch_task_profile_id of this ComputeTask. The OCID of the batch task profile used for this task.

Returns:The batch_task_profile_id of this ComputeTask.
Return type:str
command

Gets the command of this ComputeTask. An executable command to start the processing of this task.

Returns:The command of this ComputeTask.
Return type:list[str]
dependencies

[Required] Gets the dependencies of this BatchTask. A list of tasks from the same job this task depends on referenced by name.

Returns:The dependencies of this BatchTask.
Return type:list[str]
description

Gets the description of this BatchTask. An optional description that provides additional context next to the displayName.

Returns:The description of this BatchTask.
Return type:str
entitlement_claims

[Required] Gets the entitlement_claims of this BatchTask. A list of resources (for example licences) this task needs for its execution.

Returns:The entitlement_claims of this BatchTask.
Return type:list[str]
environment_variables

[Required] Gets the environment_variables of this BatchTask. Environment variables to use for the task execution.

Returns:The environment_variables of this BatchTask.
Return type:list[oci.batch.models.EnvironmentVariable]
fleet_assignment_policy

Gets the fleet_assignment_policy of this ComputeTask.

Returns:The fleet_assignment_policy of this ComputeTask.
Return type:oci.batch.models.FleetAssignmentPolicy
static get_subtype(object_dictionary)

Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.

id

[Required] Gets the id of this BatchTask. The UUID of batch task.

Returns:The id of this BatchTask.
Return type:str
lifecycle_details

Gets the lifecycle_details of this BatchTask. A message that describes the current state of the batch task in more detail. For example, can be used to provide actionable information for a resource in the Failed state.

Returns:The lifecycle_details of this BatchTask.
Return type:str
lifecycle_state

Gets the lifecycle_state of this BatchTask. The current state of the batch task.

Allowed values for this property are: “ACCEPTED”, “WAITING”, “IN_PROGRESS”, “SUCCEEDED”, “FAILED”, “CANCELING”, “CANCELED”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.

Returns:The lifecycle_state of this BatchTask.
Return type:str
name

[Required] Gets the name of this BatchTask. The name of the batch task. It must be unique within its parent batch job.

Returns:The name of this BatchTask.
Return type:str
type

[Required] Gets the type of this BatchTask. Type of the batch task. Also serves as a discriminator for sub-entities.

Allowed values for this property are: “COMPUTE”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.

Returns:The type of this BatchTask.
Return type:str