@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class ContainerInstance extends Object implements Serializable, Cloneable, StructuredPojo
An EC2 instance that is running the Amazon ECS agent and has been registered with a cluster.
Constructor and Description |
---|
ContainerInstance() |
Modifier and Type | Method and Description |
---|---|
ContainerInstance |
clone() |
boolean |
equals(Object obj) |
Boolean |
getAgentConnected()
This parameter returns
true if the agent is actually connected to Amazon ECS. |
String |
getAgentUpdateStatus()
The status of the most recent agent update.
|
List<Attribute> |
getAttributes()
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration
or manually with the PutAttributes operation.
|
String |
getContainerInstanceArn()
The Amazon Resource Name (ARN) of the container instance.
|
String |
getEc2InstanceId()
The EC2 instance ID of the container instance.
|
Integer |
getPendingTasksCount()
The number of tasks on the container instance that are in the
PENDING status. |
Date |
getRegisteredAt()
The Unix timestamp for when the container instance was registered.
|
List<Resource> |
getRegisteredResources()
For most resource types, this parameter describes the registered resources on the container instance that are in
use by current tasks.
|
List<Resource> |
getRemainingResources()
For most resource types, this parameter describes the remaining resources of the container instance that are
available for new tasks.
|
Integer |
getRunningTasksCount()
The number of tasks on the container instance that are in the
RUNNING status. |
String |
getStatus()
The status of the container instance.
|
Long |
getVersion()
The version counter for the container instance.
|
VersionInfo |
getVersionInfo()
The version information for the Amazon ECS container agent and Docker daemon running on the container instance.
|
int |
hashCode() |
Boolean |
isAgentConnected()
This parameter returns
true if the agent is actually connected to Amazon ECS. |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setAgentConnected(Boolean agentConnected)
This parameter returns
true if the agent is actually connected to Amazon ECS. |
void |
setAgentUpdateStatus(AgentUpdateStatus agentUpdateStatus)
The status of the most recent agent update.
|
void |
setAgentUpdateStatus(String agentUpdateStatus)
The status of the most recent agent update.
|
void |
setAttributes(Collection<Attribute> attributes)
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration
or manually with the PutAttributes operation.
|
void |
setContainerInstanceArn(String containerInstanceArn)
The Amazon Resource Name (ARN) of the container instance.
|
void |
setEc2InstanceId(String ec2InstanceId)
The EC2 instance ID of the container instance.
|
void |
setPendingTasksCount(Integer pendingTasksCount)
The number of tasks on the container instance that are in the
PENDING status. |
void |
setRegisteredAt(Date registeredAt)
The Unix timestamp for when the container instance was registered.
|
void |
setRegisteredResources(Collection<Resource> registeredResources)
For most resource types, this parameter describes the registered resources on the container instance that are in
use by current tasks.
|
void |
setRemainingResources(Collection<Resource> remainingResources)
For most resource types, this parameter describes the remaining resources of the container instance that are
available for new tasks.
|
void |
setRunningTasksCount(Integer runningTasksCount)
The number of tasks on the container instance that are in the
RUNNING status. |
void |
setStatus(String status)
The status of the container instance.
|
void |
setVersion(Long version)
The version counter for the container instance.
|
void |
setVersionInfo(VersionInfo versionInfo)
The version information for the Amazon ECS container agent and Docker daemon running on the container instance.
|
String |
toString()
Returns a string representation of this object; useful for testing and debugging.
|
ContainerInstance |
withAgentConnected(Boolean agentConnected)
This parameter returns
true if the agent is actually connected to Amazon ECS. |
ContainerInstance |
withAgentUpdateStatus(AgentUpdateStatus agentUpdateStatus)
The status of the most recent agent update.
|
ContainerInstance |
withAgentUpdateStatus(String agentUpdateStatus)
The status of the most recent agent update.
|
ContainerInstance |
withAttributes(Attribute... attributes)
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration
or manually with the PutAttributes operation.
|
ContainerInstance |
withAttributes(Collection<Attribute> attributes)
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration
or manually with the PutAttributes operation.
|
ContainerInstance |
withContainerInstanceArn(String containerInstanceArn)
The Amazon Resource Name (ARN) of the container instance.
|
ContainerInstance |
withEc2InstanceId(String ec2InstanceId)
The EC2 instance ID of the container instance.
|
ContainerInstance |
withPendingTasksCount(Integer pendingTasksCount)
The number of tasks on the container instance that are in the
PENDING status. |
ContainerInstance |
withRegisteredAt(Date registeredAt)
The Unix timestamp for when the container instance was registered.
|
ContainerInstance |
withRegisteredResources(Collection<Resource> registeredResources)
For most resource types, this parameter describes the registered resources on the container instance that are in
use by current tasks.
|
ContainerInstance |
withRegisteredResources(Resource... registeredResources)
For most resource types, this parameter describes the registered resources on the container instance that are in
use by current tasks.
|
ContainerInstance |
withRemainingResources(Collection<Resource> remainingResources)
For most resource types, this parameter describes the remaining resources of the container instance that are
available for new tasks.
|
ContainerInstance |
withRemainingResources(Resource... remainingResources)
For most resource types, this parameter describes the remaining resources of the container instance that are
available for new tasks.
|
ContainerInstance |
withRunningTasksCount(Integer runningTasksCount)
The number of tasks on the container instance that are in the
RUNNING status. |
ContainerInstance |
withStatus(String status)
The status of the container instance.
|
ContainerInstance |
withVersion(Long version)
The version counter for the container instance.
|
ContainerInstance |
withVersionInfo(VersionInfo versionInfo)
The version information for the Amazon ECS container agent and Docker daemon running on the container instance.
|
public void setContainerInstanceArn(String containerInstanceArn)
The Amazon Resource Name (ARN) of the container instance. The ARN contains the arn:aws:ecs
namespace, followed by the region of the container instance, the AWS account ID of the container instance owner,
the container-instance
namespace, and then the container instance ID. For example,
arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID
.
containerInstanceArn
- The Amazon Resource Name (ARN) of the container instance. The ARN contains the arn:aws:ecs
namespace, followed by the region of the container instance, the AWS account ID of the container instance
owner, the container-instance
namespace, and then the container instance ID. For example,
arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID
.public String getContainerInstanceArn()
The Amazon Resource Name (ARN) of the container instance. The ARN contains the arn:aws:ecs
namespace, followed by the region of the container instance, the AWS account ID of the container instance owner,
the container-instance
namespace, and then the container instance ID. For example,
arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID
.
arn:aws:ecs
namespace, followed by the region of the container instance, the AWS account ID of the container instance
owner, the container-instance
namespace, and then the container instance ID. For example,
arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID
.public ContainerInstance withContainerInstanceArn(String containerInstanceArn)
The Amazon Resource Name (ARN) of the container instance. The ARN contains the arn:aws:ecs
namespace, followed by the region of the container instance, the AWS account ID of the container instance owner,
the container-instance
namespace, and then the container instance ID. For example,
arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID
.
containerInstanceArn
- The Amazon Resource Name (ARN) of the container instance. The ARN contains the arn:aws:ecs
namespace, followed by the region of the container instance, the AWS account ID of the container instance
owner, the container-instance
namespace, and then the container instance ID. For example,
arn:aws:ecs:region:aws_account_id:container-instance/container_instance_ID
.public void setEc2InstanceId(String ec2InstanceId)
The EC2 instance ID of the container instance.
ec2InstanceId
- The EC2 instance ID of the container instance.public String getEc2InstanceId()
The EC2 instance ID of the container instance.
public ContainerInstance withEc2InstanceId(String ec2InstanceId)
The EC2 instance ID of the container instance.
ec2InstanceId
- The EC2 instance ID of the container instance.public void setVersion(Long version)
The version counter for the container instance. Every time a container instance experiences a change that
triggers a CloudWatch event, the version counter is incremented. If you are replicating your Amazon ECS container
instance state with CloudWatch events, you can compare the version of a container instance reported by the Amazon
ECS APIs with the version reported in CloudWatch events for the container instance (inside the
detail
object) to verify that the version in your event stream is current.
version
- The version counter for the container instance. Every time a container instance experiences a change that
triggers a CloudWatch event, the version counter is incremented. If you are replicating your Amazon ECS
container instance state with CloudWatch events, you can compare the version of a container instance
reported by the Amazon ECS APIs with the version reported in CloudWatch events for the container instance
(inside the detail
object) to verify that the version in your event stream is current.public Long getVersion()
The version counter for the container instance. Every time a container instance experiences a change that
triggers a CloudWatch event, the version counter is incremented. If you are replicating your Amazon ECS container
instance state with CloudWatch events, you can compare the version of a container instance reported by the Amazon
ECS APIs with the version reported in CloudWatch events for the container instance (inside the
detail
object) to verify that the version in your event stream is current.
detail
object) to verify that the version in your event stream is current.public ContainerInstance withVersion(Long version)
The version counter for the container instance. Every time a container instance experiences a change that
triggers a CloudWatch event, the version counter is incremented. If you are replicating your Amazon ECS container
instance state with CloudWatch events, you can compare the version of a container instance reported by the Amazon
ECS APIs with the version reported in CloudWatch events for the container instance (inside the
detail
object) to verify that the version in your event stream is current.
version
- The version counter for the container instance. Every time a container instance experiences a change that
triggers a CloudWatch event, the version counter is incremented. If you are replicating your Amazon ECS
container instance state with CloudWatch events, you can compare the version of a container instance
reported by the Amazon ECS APIs with the version reported in CloudWatch events for the container instance
(inside the detail
object) to verify that the version in your event stream is current.public void setVersionInfo(VersionInfo versionInfo)
The version information for the Amazon ECS container agent and Docker daemon running on the container instance.
versionInfo
- The version information for the Amazon ECS container agent and Docker daemon running on the container
instance.public VersionInfo getVersionInfo()
The version information for the Amazon ECS container agent and Docker daemon running on the container instance.
public ContainerInstance withVersionInfo(VersionInfo versionInfo)
The version information for the Amazon ECS container agent and Docker daemon running on the container instance.
versionInfo
- The version information for the Amazon ECS container agent and Docker daemon running on the container
instance.public List<Resource> getRemainingResources()
For most resource types, this parameter describes the remaining resources of the container instance that are available for new tasks. For port resource types, this parameter describes the ports that are reserved by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is not specified here is available for new tasks.
public void setRemainingResources(Collection<Resource> remainingResources)
For most resource types, this parameter describes the remaining resources of the container instance that are available for new tasks. For port resource types, this parameter describes the ports that are reserved by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is not specified here is available for new tasks.
remainingResources
- For most resource types, this parameter describes the remaining resources of the container instance that
are available for new tasks. For port resource types, this parameter describes the ports that are reserved
by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is
not specified here is available for new tasks.public ContainerInstance withRemainingResources(Resource... remainingResources)
For most resource types, this parameter describes the remaining resources of the container instance that are available for new tasks. For port resource types, this parameter describes the ports that are reserved by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is not specified here is available for new tasks.
NOTE: This method appends the values to the existing list (if any). Use
setRemainingResources(java.util.Collection)
or withRemainingResources(java.util.Collection)
if
you want to override the existing values.
remainingResources
- For most resource types, this parameter describes the remaining resources of the container instance that
are available for new tasks. For port resource types, this parameter describes the ports that are reserved
by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is
not specified here is available for new tasks.public ContainerInstance withRemainingResources(Collection<Resource> remainingResources)
For most resource types, this parameter describes the remaining resources of the container instance that are available for new tasks. For port resource types, this parameter describes the ports that are reserved by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is not specified here is available for new tasks.
remainingResources
- For most resource types, this parameter describes the remaining resources of the container instance that
are available for new tasks. For port resource types, this parameter describes the ports that are reserved
by the Amazon ECS container agent and any containers that have reserved port mappings; any port that is
not specified here is available for new tasks.public List<Resource> getRegisteredResources()
For most resource types, this parameter describes the registered resources on the container instance that are in use by current tasks. For port resource types, this parameter describes the ports that were reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.
public void setRegisteredResources(Collection<Resource> registeredResources)
For most resource types, this parameter describes the registered resources on the container instance that are in use by current tasks. For port resource types, this parameter describes the ports that were reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.
registeredResources
- For most resource types, this parameter describes the registered resources on the container instance that
are in use by current tasks. For port resource types, this parameter describes the ports that were
reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.public ContainerInstance withRegisteredResources(Resource... registeredResources)
For most resource types, this parameter describes the registered resources on the container instance that are in use by current tasks. For port resource types, this parameter describes the ports that were reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.
NOTE: This method appends the values to the existing list (if any). Use
setRegisteredResources(java.util.Collection)
or withRegisteredResources(java.util.Collection)
if you want to override the existing values.
registeredResources
- For most resource types, this parameter describes the registered resources on the container instance that
are in use by current tasks. For port resource types, this parameter describes the ports that were
reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.public ContainerInstance withRegisteredResources(Collection<Resource> registeredResources)
For most resource types, this parameter describes the registered resources on the container instance that are in use by current tasks. For port resource types, this parameter describes the ports that were reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.
registeredResources
- For most resource types, this parameter describes the registered resources on the container instance that
are in use by current tasks. For port resource types, this parameter describes the ports that were
reserved by the Amazon ECS container agent when it registered the container instance with Amazon ECS.public void setStatus(String status)
The status of the container instance. The valid values are ACTIVE
, INACTIVE
, or
DRAINING
. ACTIVE
indicates that the container instance can accept tasks.
DRAINING
indicates that new tasks are not placed on the container instance and any service tasks
running on the container instance are removed if possible. For more information, see Container
Instance Draining in the Amazon EC2 Container Service Developer Guide.
status
- The status of the container instance. The valid values are ACTIVE
, INACTIVE
, or
DRAINING
. ACTIVE
indicates that the container instance can accept tasks.
DRAINING
indicates that new tasks are not placed on the container instance and any service
tasks running on the container instance are removed if possible. For more information, see Container Instance Draining in the Amazon EC2 Container Service Developer Guide.public String getStatus()
The status of the container instance. The valid values are ACTIVE
, INACTIVE
, or
DRAINING
. ACTIVE
indicates that the container instance can accept tasks.
DRAINING
indicates that new tasks are not placed on the container instance and any service tasks
running on the container instance are removed if possible. For more information, see Container
Instance Draining in the Amazon EC2 Container Service Developer Guide.
ACTIVE
, INACTIVE
, or
DRAINING
. ACTIVE
indicates that the container instance can accept tasks.
DRAINING
indicates that new tasks are not placed on the container instance and any service
tasks running on the container instance are removed if possible. For more information, see Container Instance Draining in the Amazon EC2 Container Service Developer Guide.public ContainerInstance withStatus(String status)
The status of the container instance. The valid values are ACTIVE
, INACTIVE
, or
DRAINING
. ACTIVE
indicates that the container instance can accept tasks.
DRAINING
indicates that new tasks are not placed on the container instance and any service tasks
running on the container instance are removed if possible. For more information, see Container
Instance Draining in the Amazon EC2 Container Service Developer Guide.
status
- The status of the container instance. The valid values are ACTIVE
, INACTIVE
, or
DRAINING
. ACTIVE
indicates that the container instance can accept tasks.
DRAINING
indicates that new tasks are not placed on the container instance and any service
tasks running on the container instance are removed if possible. For more information, see Container Instance Draining in the Amazon EC2 Container Service Developer Guide.public void setAgentConnected(Boolean agentConnected)
This parameter returns true
if the agent is actually connected to Amazon ECS. Registered instances
with an agent that may be unhealthy or stopped return false
, and instances without a connected agent
cannot accept placement requests.
agentConnected
- This parameter returns true
if the agent is actually connected to Amazon ECS. Registered
instances with an agent that may be unhealthy or stopped return false
, and instances without
a connected agent cannot accept placement requests.public Boolean getAgentConnected()
This parameter returns true
if the agent is actually connected to Amazon ECS. Registered instances
with an agent that may be unhealthy or stopped return false
, and instances without a connected agent
cannot accept placement requests.
true
if the agent is actually connected to Amazon ECS. Registered
instances with an agent that may be unhealthy or stopped return false
, and instances without
a connected agent cannot accept placement requests.public ContainerInstance withAgentConnected(Boolean agentConnected)
This parameter returns true
if the agent is actually connected to Amazon ECS. Registered instances
with an agent that may be unhealthy or stopped return false
, and instances without a connected agent
cannot accept placement requests.
agentConnected
- This parameter returns true
if the agent is actually connected to Amazon ECS. Registered
instances with an agent that may be unhealthy or stopped return false
, and instances without
a connected agent cannot accept placement requests.public Boolean isAgentConnected()
This parameter returns true
if the agent is actually connected to Amazon ECS. Registered instances
with an agent that may be unhealthy or stopped return false
, and instances without a connected agent
cannot accept placement requests.
true
if the agent is actually connected to Amazon ECS. Registered
instances with an agent that may be unhealthy or stopped return false
, and instances without
a connected agent cannot accept placement requests.public void setRunningTasksCount(Integer runningTasksCount)
The number of tasks on the container instance that are in the RUNNING
status.
runningTasksCount
- The number of tasks on the container instance that are in the RUNNING
status.public Integer getRunningTasksCount()
The number of tasks on the container instance that are in the RUNNING
status.
RUNNING
status.public ContainerInstance withRunningTasksCount(Integer runningTasksCount)
The number of tasks on the container instance that are in the RUNNING
status.
runningTasksCount
- The number of tasks on the container instance that are in the RUNNING
status.public void setPendingTasksCount(Integer pendingTasksCount)
The number of tasks on the container instance that are in the PENDING
status.
pendingTasksCount
- The number of tasks on the container instance that are in the PENDING
status.public Integer getPendingTasksCount()
The number of tasks on the container instance that are in the PENDING
status.
PENDING
status.public ContainerInstance withPendingTasksCount(Integer pendingTasksCount)
The number of tasks on the container instance that are in the PENDING
status.
pendingTasksCount
- The number of tasks on the container instance that are in the PENDING
status.public void setAgentUpdateStatus(String agentUpdateStatus)
The status of the most recent agent update. If an update has never been requested, this value is
NULL
.
agentUpdateStatus
- The status of the most recent agent update. If an update has never been requested, this value is
NULL
.AgentUpdateStatus
public String getAgentUpdateStatus()
The status of the most recent agent update. If an update has never been requested, this value is
NULL
.
NULL
.AgentUpdateStatus
public ContainerInstance withAgentUpdateStatus(String agentUpdateStatus)
The status of the most recent agent update. If an update has never been requested, this value is
NULL
.
agentUpdateStatus
- The status of the most recent agent update. If an update has never been requested, this value is
NULL
.AgentUpdateStatus
public void setAgentUpdateStatus(AgentUpdateStatus agentUpdateStatus)
The status of the most recent agent update. If an update has never been requested, this value is
NULL
.
agentUpdateStatus
- The status of the most recent agent update. If an update has never been requested, this value is
NULL
.AgentUpdateStatus
public ContainerInstance withAgentUpdateStatus(AgentUpdateStatus agentUpdateStatus)
The status of the most recent agent update. If an update has never been requested, this value is
NULL
.
agentUpdateStatus
- The status of the most recent agent update. If an update has never been requested, this value is
NULL
.AgentUpdateStatus
public List<Attribute> getAttributes()
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration or manually with the PutAttributes operation.
public void setAttributes(Collection<Attribute> attributes)
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration or manually with the PutAttributes operation.
attributes
- The attributes set for the container instance, either by the Amazon ECS container agent at instance
registration or manually with the PutAttributes operation.public ContainerInstance withAttributes(Attribute... attributes)
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration or manually with the PutAttributes operation.
NOTE: This method appends the values to the existing list (if any). Use
setAttributes(java.util.Collection)
or withAttributes(java.util.Collection)
if you want to
override the existing values.
attributes
- The attributes set for the container instance, either by the Amazon ECS container agent at instance
registration or manually with the PutAttributes operation.public ContainerInstance withAttributes(Collection<Attribute> attributes)
The attributes set for the container instance, either by the Amazon ECS container agent at instance registration or manually with the PutAttributes operation.
attributes
- The attributes set for the container instance, either by the Amazon ECS container agent at instance
registration or manually with the PutAttributes operation.public void setRegisteredAt(Date registeredAt)
The Unix timestamp for when the container instance was registered.
registeredAt
- The Unix timestamp for when the container instance was registered.public Date getRegisteredAt()
The Unix timestamp for when the container instance was registered.
public ContainerInstance withRegisteredAt(Date registeredAt)
The Unix timestamp for when the container instance was registered.
registeredAt
- The Unix timestamp for when the container instance was registered.public String toString()
toString
in class Object
Object.toString()
public ContainerInstance clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.Copyright © 2013 Amazon Web Services, Inc. All Rights Reserved.