Class StateReason

java.lang.Object
com.amazonaws.services.ec2.model.StateReason
All Implemented Interfaces:
Serializable, Cloneable

public class StateReason extends Object implements Serializable, Cloneable

Describes a state change.

See Also:
  • Constructor Details

    • StateReason

      public StateReason()
  • Method Details

    • setCode

      public void setCode(String code)

      The reason code for the state change.

      Parameters:
      code - The reason code for the state change.
    • getCode

      public String getCode()

      The reason code for the state change.

      Returns:
      The reason code for the state change.
    • withCode

      public StateReason withCode(String code)

      The reason code for the state change.

      Parameters:
      code - The reason code for the state change.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setMessage

      public void setMessage(String message)

      The message for the state change.

      • Server.SpotInstanceTermination: A Spot instance was terminated due to an increase in the market price.

      • Server.InternalError: An internal error occurred during instance launch, resulting in termination.

      • Server.InsufficientInstanceCapacity: There was insufficient instance capacity to satisfy the launch request.

      • Client.InternalError: A client error caused the instance to terminate on launch.

      • Client.InstanceInitiatedShutdown: The instance was shut down using the shutdown -h command from the instance.

      • Client.UserInitiatedShutdown: The instance was shut down using the Amazon EC2 API.

      • Client.VolumeLimitExceeded: The limit on the number of EBS volumes or total storage was exceeded. Decrease usage or request an increase in your limits.

      • Client.InvalidSnapshot.NotFound: The specified snapshot was not found.

      Parameters:
      message - The message for the state change.

      • Server.SpotInstanceTermination: A Spot instance was terminated due to an increase in the market price.

      • Server.InternalError: An internal error occurred during instance launch, resulting in termination.

      • Server.InsufficientInstanceCapacity: There was insufficient instance capacity to satisfy the launch request.

      • Client.InternalError: A client error caused the instance to terminate on launch.

      • Client.InstanceInitiatedShutdown: The instance was shut down using the shutdown -h command from the instance.

      • Client.UserInitiatedShutdown: The instance was shut down using the Amazon EC2 API.

      • Client.VolumeLimitExceeded: The limit on the number of EBS volumes or total storage was exceeded. Decrease usage or request an increase in your limits.

      • Client.InvalidSnapshot.NotFound: The specified snapshot was not found.

    • getMessage

      public String getMessage()

      The message for the state change.

      • Server.SpotInstanceTermination: A Spot instance was terminated due to an increase in the market price.

      • Server.InternalError: An internal error occurred during instance launch, resulting in termination.

      • Server.InsufficientInstanceCapacity: There was insufficient instance capacity to satisfy the launch request.

      • Client.InternalError: A client error caused the instance to terminate on launch.

      • Client.InstanceInitiatedShutdown: The instance was shut down using the shutdown -h command from the instance.

      • Client.UserInitiatedShutdown: The instance was shut down using the Amazon EC2 API.

      • Client.VolumeLimitExceeded: The limit on the number of EBS volumes or total storage was exceeded. Decrease usage or request an increase in your limits.

      • Client.InvalidSnapshot.NotFound: The specified snapshot was not found.

      Returns:
      The message for the state change.

      • Server.SpotInstanceTermination: A Spot instance was terminated due to an increase in the market price.

      • Server.InternalError: An internal error occurred during instance launch, resulting in termination.

      • Server.InsufficientInstanceCapacity: There was insufficient instance capacity to satisfy the launch request.

      • Client.InternalError: A client error caused the instance to terminate on launch.

      • Client.InstanceInitiatedShutdown: The instance was shut down using the shutdown -h command from the instance.

      • Client.UserInitiatedShutdown: The instance was shut down using the Amazon EC2 API.

      • Client.VolumeLimitExceeded: The limit on the number of EBS volumes or total storage was exceeded. Decrease usage or request an increase in your limits.

      • Client.InvalidSnapshot.NotFound: The specified snapshot was not found.

    • withMessage

      public StateReason withMessage(String message)

      The message for the state change.

      • Server.SpotInstanceTermination: A Spot instance was terminated due to an increase in the market price.

      • Server.InternalError: An internal error occurred during instance launch, resulting in termination.

      • Server.InsufficientInstanceCapacity: There was insufficient instance capacity to satisfy the launch request.

      • Client.InternalError: A client error caused the instance to terminate on launch.

      • Client.InstanceInitiatedShutdown: The instance was shut down using the shutdown -h command from the instance.

      • Client.UserInitiatedShutdown: The instance was shut down using the Amazon EC2 API.

      • Client.VolumeLimitExceeded: The limit on the number of EBS volumes or total storage was exceeded. Decrease usage or request an increase in your limits.

      • Client.InvalidSnapshot.NotFound: The specified snapshot was not found.

      Parameters:
      message - The message for the state change.

      • Server.SpotInstanceTermination: A Spot instance was terminated due to an increase in the market price.

      • Server.InternalError: An internal error occurred during instance launch, resulting in termination.

      • Server.InsufficientInstanceCapacity: There was insufficient instance capacity to satisfy the launch request.

      • Client.InternalError: A client error caused the instance to terminate on launch.

      • Client.InstanceInitiatedShutdown: The instance was shut down using the shutdown -h command from the instance.

      • Client.UserInitiatedShutdown: The instance was shut down using the Amazon EC2 API.

      • Client.VolumeLimitExceeded: The limit on the number of EBS volumes or total storage was exceeded. Decrease usage or request an increase in your limits.

      • Client.InvalidSnapshot.NotFound: The specified snapshot was not found.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • toString

      public String toString()
      Returns a string representation of this object; useful for testing and debugging.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this object.
      See Also:
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • clone

      public StateReason clone()
      Overrides:
      clone in class Object