You are viewing documentation for version 3 of the AWS SDK for Ruby. Version 2 documentation can be found here.

Class: Aws::ECS::Types::Task

Inherits:
Struct
  • Object
show all
Defined in:
gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb

Overview

Details on a task in a cluster.

Instance Attribute Summary collapse

Instance Attribute Details

#cluster_arnString

The Amazon Resource Name (ARN) of the cluster that hosts the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#container_instance_arnString

The Amazon Resource Name (ARN) of the container instances that host the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#containersArray<Types::Container>

The containers associated with the task.

Returns:



3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#created_atTime

The Unix timestamp for when the task was created (the task entered the PENDING state).

Returns:

  • (Time)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#desired_statusString

The desired status of the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#groupString

The name of the task group associated with the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#last_statusString

The last known status of the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#overridesTypes::TaskOverride

One or more container overrides.

Returns:



3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#started_atTime

The Unix timestamp for when the task was started (the task transitioned from the PENDING state to the RUNNING state).

Returns:

  • (Time)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#started_byString

The tag specified when a task is started. If the task is started by an Amazon ECS service, then the startedBy parameter contains the deployment ID of the service that starts it.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#stopped_atTime

The Unix timestamp for when the task was stopped (the task transitioned from the RUNNING state to the STOPPED state).

Returns:

  • (Time)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#stopped_reasonString

The reason the task was stopped.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#task_arnString

The Amazon Resource Name (ARN) of the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#task_definition_arnString

The Amazon Resource Name (ARN) of the task definition that creates the task.

Returns:

  • (String)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end

#versionInteger

The version counter for the task. Every time a task experiences a change that triggers a CloudWatch event, the version counter is incremented. If you are replicating your Amazon ECS task state with CloudWatch events, you can compare the version of a task reported by the Amazon ECS APIs with the version reported in CloudWatch events for the task (inside the detail object) to verify that the version in your event stream is current.

Returns:

  • (Integer)


3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
# File 'gems/aws-sdk-ecs/lib/aws-sdk-ecs/types.rb', line 3865

class Task < Struct.new(
  :task_arn,
  :cluster_arn,
  :task_definition_arn,
  :container_instance_arn,
  :overrides,
  :last_status,
  :desired_status,
  :containers,
  :started_by,
  :version,
  :stopped_reason,
  :created_at,
  :started_at,
  :stopped_at,
  :group)
  include Aws::Structure
end