BatchJob¶
- class oci.batch.models.BatchJob(**kwargs)¶
Bases:
objectA batch job represents the execution unit that is invoked on a batch’s pools of compute resources. A job is composed of one or more tasks, which are the executable commands.
To use any of the API operations, you must be authorized in an IAM policy. If you’re not authorized, talk to an administrator. If you’re an administrator who needs to write policies to give users access, see Getting Started with Policies.
Attributes:
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
A constant which can be used with the lifecycle_state property of a BatchJob.
[Required] Gets the batch_context_id of this BatchJob.
[Required] Gets the batch_job_pool_id of this BatchJob.
[Required] Gets the compartment_id of this BatchJob.
[Required] Gets the defined_tags of this BatchJob.
Gets the description of this BatchJob.
[Required] Gets the display_name of this BatchJob.
Gets the environment_variables of this BatchJob.
[Required] Gets the freeform_tags of this BatchJob.
[Required] Gets the id of this BatchJob.
Gets the lifecycle_details of this BatchJob.
[Required] Gets the lifecycle_state of this BatchJob.
Gets the priority of this BatchJob.
Gets the progress_details of this BatchJob.
Gets the progress_percentage of this BatchJob.
[Required] Gets the system_tags of this BatchJob.
[Required] Gets the time_created of this BatchJob.
Gets the time_updated of this BatchJob.
Methods:
__init__(**kwargs)Initializes a new BatchJob object with values from keyword arguments.
- LIFECYCLE_STATE_ACCEPTED = 'ACCEPTED'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “ACCEPTED”
- LIFECYCLE_STATE_CANCELED = 'CANCELED'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “CANCELED”
- LIFECYCLE_STATE_CANCELING = 'CANCELING'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “CANCELING”
- LIFECYCLE_STATE_FAILED = 'FAILED'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “FAILED”
- LIFECYCLE_STATE_IN_PROGRESS = 'IN_PROGRESS'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “IN_PROGRESS”
- LIFECYCLE_STATE_NEEDS_ATTENTION = 'NEEDS_ATTENTION'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “NEEDS_ATTENTION”
- LIFECYCLE_STATE_SUCCEEDED = 'SUCCEEDED'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “SUCCEEDED”
- LIFECYCLE_STATE_WAITING = 'WAITING'¶
A constant which can be used with the lifecycle_state property of a BatchJob. This constant has a value of “WAITING”
- __init__(**kwargs)¶
Initializes a new BatchJob object with values from keyword arguments. 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 BatchJob.
compartment_id (str) – The value to assign to the compartment_id property of this BatchJob.
batch_job_pool_id (str) – The value to assign to the batch_job_pool_id property of this BatchJob.
batch_context_id (str) – The value to assign to the batch_context_id property of this BatchJob.
display_name (str) – The value to assign to the display_name property of this BatchJob.
description (str) – The value to assign to the description property of this BatchJob.
priority (int) – The value to assign to the priority property of this BatchJob.
progress_percentage (int) – The value to assign to the progress_percentage property of this BatchJob.
progress_details (str) – The value to assign to the progress_details property of this BatchJob.
environment_variables (list[oci.batch.models.EnvironmentVariable]) – The value to assign to the environment_variables property of this BatchJob.
time_created (datetime) – The value to assign to the time_created property of this BatchJob.
time_updated (datetime) – The value to assign to the time_updated property of this BatchJob.
lifecycle_state (str) – The value to assign to the lifecycle_state property of this BatchJob. Allowed values for this property are: “ACCEPTED”, “WAITING”, “IN_PROGRESS”, “SUCCEEDED”, “NEEDS_ATTENTION”, “FAILED”, “CANCELING”, “CANCELED”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
lifecycle_details (str) – The value to assign to the lifecycle_details property of this BatchJob.
freeform_tags (dict(str, str)) – The value to assign to the freeform_tags property of this BatchJob.
defined_tags (dict(str, dict(str, object))) – The value to assign to the defined_tags property of this BatchJob.
system_tags (dict(str, dict(str, object))) – The value to assign to the system_tags property of this BatchJob.
- property batch_context_id¶
[Required] Gets the batch_context_id of this BatchJob. The OCID of the parent batch context of the parent job pool.
- Returns
The batch_context_id of this BatchJob.
- Return type
str
- property batch_job_pool_id¶
[Required] Gets the batch_job_pool_id of this BatchJob. The OCID of the parent batch job pool.
- Returns
The batch_job_pool_id of this BatchJob.
- Return type
str
- property compartment_id¶
[Required] Gets the compartment_id of this BatchJob. The OCID of the compartment.
- Returns
The compartment_id of this BatchJob.
- Return type
str
- property defined_tags¶
[Required] Gets the defined_tags of this BatchJob. Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags.
Example: {“Operations”: {“CostCenter”: “42”}}
- Returns
The defined_tags of this BatchJob.
- Return type
dict(str, dict(str, object))
- property description¶
Gets the description of this BatchJob. An optional description that provides additional context next to the displayName.
- Returns
The description of this BatchJob.
- Return type
str
- property display_name¶
[Required] Gets the display_name of this BatchJob. A user-friendly name. Does not have to be unique, and it’s changeable.
- Returns
The display_name of this BatchJob.
- Return type
str
- property environment_variables¶
Gets the environment_variables of this BatchJob. An environment variables to use for the job’s tasks (can be overridden by task’s environment variables).
- Returns
The environment_variables of this BatchJob.
- Return type
- property freeform_tags¶
[Required] Gets the freeform_tags of this BatchJob. Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags.
Example: {“Department”: “Finance”}
- Returns
The freeform_tags of this BatchJob.
- Return type
dict(str, str)
- property id¶
[Required] Gets the id of this BatchJob. The OCID of the batch job.
- Returns
The id of this BatchJob.
- Return type
str
- property lifecycle_details¶
Gets the lifecycle_details of this BatchJob. A message that describes the current state of the batch job 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 BatchJob.
- Return type
str
- property lifecycle_state¶
[Required] Gets the lifecycle_state of this BatchJob. The current state of the batch job.
Allowed values for this property are: “ACCEPTED”, “WAITING”, “IN_PROGRESS”, “SUCCEEDED”, “NEEDS_ATTENTION”, “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 BatchJob.
- Return type
str
- property priority¶
Gets the priority of this BatchJob. A value calculated by the system based on the priority tags.
- Returns
The priority of this BatchJob.
- Return type
int
- property progress_details¶
Gets the progress_details of this BatchJob. A more detailed textual representation of the job completion.
- Returns
The progress_details of this BatchJob.
- Return type
str
- property progress_percentage¶
Gets the progress_percentage of this BatchJob. A percentage value (0..100) of the job completion.
- Returns
The progress_percentage of this BatchJob.
- Return type
int
- property system_tags¶
[Required] Gets the system_tags of this BatchJob. System tags for this resource. Each key is predefined and scoped to a namespace.
Example: {“orcl-cloud”: {“free-tier-retained”: “true”}}
- Returns
The system_tags of this BatchJob.
- Return type
dict(str, dict(str, object))