com.atlassian.bamboo.agent.elastic.server
Class ElasticImageConfigurationImpl

java.lang.Object
  extended by com.atlassian.core.bean.EntityObject
      extended by com.atlassian.bamboo.core.BambooEntityObject
          extended by com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl
All Implemented Interfaces:
ElasticImageConfiguration, BambooIdProvider, BambooObject, java.lang.Cloneable, java.lang.Comparable<ElasticImageConfigurationImpl>

public class ElasticImageConfigurationImpl
extends BambooEntityObject
implements ElasticImageConfiguration, java.lang.Comparable<ElasticImageConfigurationImpl>


Field Summary
 
Fields inherited from class com.atlassian.bamboo.core.BambooEntityObject
id
 
Constructor Summary
ElasticImageConfigurationImpl()
           
 
Method Summary
 int compareTo(ElasticImageConfigurationImpl o)
           
 boolean equals(java.lang.Object o)
          This method needs to be here in order to use proper id
 java.lang.String getAmiId()
          Get Elastic Instance Configuration's EC2 AMI id.
 com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Architecture getArchitecture()
          Get image architecture
 java.lang.String getAvailabilityZone()
          Get Availability Zone for Elastic Instance Configuration.
 ImageCapabilitySet getCapabilitySet()
           
 java.lang.String getConfigurationDescription()
          Get Elastic Instance Configuration's description.
 java.lang.String getConfigurationName()
          Get Elastic Instance Configuration's name.
 java.lang.String getEbsSnapshotId()
          Get Elastic Instance Configuration's EBS snapshot id.
 java.lang.String getImageFilesVersion()
           
 com.atlassian.aws.ec2.EC2InstanceType getInstanceType()
          Get Elastic Instance Configuration type.
 com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Platform getPlatform()
          Get image platform
 java.lang.String getProduct()
           
 com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Region getRegion()
          Get Region for which the image configuration is defined.
 com.atlassian.aws.ec2.awssdk.AwsSupportConstants.RootDeviceType getRootDeviceType()
           
 java.util.List<Script> getStartupScripts()
           
 java.lang.String getSubnetId()
           
 int hashCode()
          This method needs to be here in order to use proper id
 boolean isDedicated()
           
 boolean isDisabled()
           
 boolean isEbsEnabled()
          Get Elastic Instance Configuration's EBS status.
 boolean isShippedWithBamboo()
          Is set for default configuration.
 void setAmiId(java.lang.String amiId)
          Set the Elastic Instance Configuration's EC2 AMI id (image)
 void setArchitecture(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Architecture architecture)
           
 void setAvailabilityZone(java.lang.String availabilityZone)
          Set Availability Zone for Elastic Instance Configuration.
 void setCapabilitySet(ImageCapabilitySet imageCapabilitySet)
           
 void setConfigurationDescription(java.lang.String configurationDescription)
           
 void setConfigurationName(java.lang.String configurationName)
           
 void setDisabled(boolean disabled)
          Set Disabled field for Elastic Instance Configuration
 void setEbsSnapshotId(java.lang.String ebsSnapshotId)
           
 void setImageFilesVersion(java.lang.String imageFilesLevel)
           
 void setInstanceType(com.atlassian.aws.ec2.EC2InstanceType instanceType)
           
 void setPlatform(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Platform platform)
           
 void setProduct(java.lang.String product)
           
 void setRegion(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Region region)
           
 void setRootDeviceType(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.RootDeviceType rootDeviceType)
           
 void setShippedWithBamboo(boolean shippedWithBamboo)
           
 void setStartupScripts(java.util.List<Script> startupScripts)
           
 void setSubnetId(java.lang.String subnetId)
          Subnet id in the "subnet-xxxxx" format
 
Methods inherited from class com.atlassian.bamboo.core.BambooEntityObject
getId, setId
 
Methods inherited from class com.atlassian.core.bean.EntityObject
clone, getCreationDate, getCurrentDate, getLastModificationDate, setClock, setCreationDate, setLastModificationDate
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.atlassian.bamboo.core.BambooObject
setId
 
Methods inherited from interface com.atlassian.bamboo.core.BambooIdProvider
getId
 

Constructor Detail

ElasticImageConfigurationImpl

public ElasticImageConfigurationImpl()
Method Detail

getConfigurationName

public java.lang.String getConfigurationName()
Description copied from interface: ElasticImageConfiguration
Get Elastic Instance Configuration's name.

Specified by:
getConfigurationName in interface ElasticImageConfiguration
Returns:
Elastic Instance Configuration's name

setConfigurationName

public void setConfigurationName(java.lang.String configurationName)
Specified by:
setConfigurationName in interface ElasticImageConfiguration

getAmiId

public java.lang.String getAmiId()
Description copied from interface: ElasticImageConfiguration
Get Elastic Instance Configuration's EC2 AMI id.

Specified by:
getAmiId in interface ElasticImageConfiguration
Returns:
Elastic Instance Configuration's EC2 AMI id

setAmiId

public void setAmiId(java.lang.String amiId)
Description copied from interface: ElasticImageConfiguration
Set the Elastic Instance Configuration's EC2 AMI id (image)

Specified by:
setAmiId in interface ElasticImageConfiguration
Parameters:
amiId - - Elastic Instance Configuration's EC2 AMI id

isEbsEnabled

public boolean isEbsEnabled()
Description copied from interface: ElasticImageConfiguration
Get Elastic Instance Configuration's EBS status.

Specified by:
isEbsEnabled in interface ElasticImageConfiguration
Returns:
Elastic Instance Configuration's EBS status

getEbsSnapshotId

public java.lang.String getEbsSnapshotId()
Description copied from interface: ElasticImageConfiguration
Get Elastic Instance Configuration's EBS snapshot id.

Specified by:
getEbsSnapshotId in interface ElasticImageConfiguration
Returns:
Elastic Instance Configuration's EBS snapshot id

setEbsSnapshotId

public void setEbsSnapshotId(@Nullable
                             java.lang.String ebsSnapshotId)

getInstanceType

@NotNull
public com.atlassian.aws.ec2.EC2InstanceType getInstanceType()
Description copied from interface: ElasticImageConfiguration
Get Elastic Instance Configuration type.

Specified by:
getInstanceType in interface ElasticImageConfiguration
Returns:
Elastic Instance Configuration type

setInstanceType

public void setInstanceType(com.atlassian.aws.ec2.EC2InstanceType instanceType)
Specified by:
setInstanceType in interface ElasticImageConfiguration

getAvailabilityZone

public java.lang.String getAvailabilityZone()
Description copied from interface: ElasticImageConfiguration
Get Availability Zone for Elastic Instance Configuration.

Specified by:
getAvailabilityZone in interface ElasticImageConfiguration
Returns:
Name of Availability Zone

setAvailabilityZone

public void setAvailabilityZone(java.lang.String availabilityZone)
Description copied from interface: ElasticImageConfiguration
Set Availability Zone for Elastic Instance Configuration.

Specified by:
setAvailabilityZone in interface ElasticImageConfiguration
Parameters:
availabilityZone - Name of Availability Zone to be setup. null if the default zone should be used

getConfigurationDescription

public java.lang.String getConfigurationDescription()
Description copied from interface: ElasticImageConfiguration
Get Elastic Instance Configuration's description.

Specified by:
getConfigurationDescription in interface ElasticImageConfiguration
Returns:
Elastic Instance Configuration's description

setConfigurationDescription

public void setConfigurationDescription(java.lang.String configurationDescription)
Specified by:
setConfigurationDescription in interface ElasticImageConfiguration

isShippedWithBamboo

public boolean isShippedWithBamboo()
Description copied from interface: ElasticImageConfiguration
Is set for default configuration. Currently it is configuration shipped with Bamboo

Specified by:
isShippedWithBamboo in interface ElasticImageConfiguration
Returns:
True if configuration is marked as "shipped with Bamboo"

setShippedWithBamboo

public void setShippedWithBamboo(boolean shippedWithBamboo)
Specified by:
setShippedWithBamboo in interface ElasticImageConfiguration

isDisabled

public boolean isDisabled()
Specified by:
isDisabled in interface ElasticImageConfiguration
Returns:
returns whether the Elastic Configuration is disabled

setDisabled

public void setDisabled(boolean disabled)
Description copied from interface: ElasticImageConfiguration
Set Disabled field for Elastic Instance Configuration

Specified by:
setDisabled in interface ElasticImageConfiguration

getCapabilitySet

@NotNull
public ImageCapabilitySet getCapabilitySet()
Specified by:
getCapabilitySet in interface ElasticImageConfiguration
Returns:
Capability Set associated with this Elastic Instance Configuration

setCapabilitySet

public void setCapabilitySet(@NotNull
                             ImageCapabilitySet imageCapabilitySet)

getProduct

@NotNull
public java.lang.String getProduct()
Specified by:
getProduct in interface ElasticImageConfiguration
Returns:
the EC2 product used to launch this image (e.g. "Linux/UNIX", "Windows", "SUSE Linux"

setProduct

public void setProduct(java.lang.String product)
Specified by:
setProduct in interface ElasticImageConfiguration

getRegion

public com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Region getRegion()
Description copied from interface: ElasticImageConfiguration
Get Region for which the image configuration is defined.

Specified by:
getRegion in interface ElasticImageConfiguration
Returns:

getSubnetId

@Nullable
public java.lang.String getSubnetId()
Specified by:
getSubnetId in interface ElasticImageConfiguration

setSubnetId

public void setSubnetId(@Nullable
                        java.lang.String subnetId)
Description copied from interface: ElasticImageConfiguration
Subnet id in the "subnet-xxxxx" format

Specified by:
setSubnetId in interface ElasticImageConfiguration

setRegion

public void setRegion(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Region region)
Specified by:
setRegion in interface ElasticImageConfiguration

getArchitecture

public com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Architecture getArchitecture()
Description copied from interface: ElasticImageConfiguration
Get image architecture

Specified by:
getArchitecture in interface ElasticImageConfiguration
Returns:

setArchitecture

public void setArchitecture(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Architecture architecture)
Specified by:
setArchitecture in interface ElasticImageConfiguration

getPlatform

public com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Platform getPlatform()
Description copied from interface: ElasticImageConfiguration
Get image platform

Specified by:
getPlatform in interface ElasticImageConfiguration
Returns:

setPlatform

public void setPlatform(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.Platform platform)
Specified by:
setPlatform in interface ElasticImageConfiguration

getRootDeviceType

public com.atlassian.aws.ec2.awssdk.AwsSupportConstants.RootDeviceType getRootDeviceType()
Specified by:
getRootDeviceType in interface ElasticImageConfiguration
Returns:
root device type for image

setRootDeviceType

public void setRootDeviceType(com.atlassian.aws.ec2.awssdk.AwsSupportConstants.RootDeviceType rootDeviceType)
Specified by:
setRootDeviceType in interface ElasticImageConfiguration

getStartupScripts

@NotNull
public java.util.List<Script> getStartupScripts()
Specified by:
getStartupScripts in interface ElasticImageConfiguration

setStartupScripts

public void setStartupScripts(@NotNull
                              java.util.List<Script> startupScripts)
Specified by:
setStartupScripts in interface ElasticImageConfiguration

getImageFilesVersion

public java.lang.String getImageFilesVersion()
Specified by:
getImageFilesVersion in interface ElasticImageConfiguration

setImageFilesVersion

public void setImageFilesVersion(java.lang.String imageFilesLevel)
Specified by:
setImageFilesVersion in interface ElasticImageConfiguration

isDedicated

public boolean isDedicated()
Specified by:
isDedicated in interface ElasticImageConfiguration
Returns:
true iff this configuration is assigned to specific jobs

hashCode

public int hashCode()
Description copied from class: BambooEntityObject
This method needs to be here in order to use proper id

Overrides:
hashCode in class BambooEntityObject

equals

public boolean equals(java.lang.Object o)
Description copied from class: BambooEntityObject
This method needs to be here in order to use proper id

Overrides:
equals in class BambooEntityObject

compareTo

public int compareTo(ElasticImageConfigurationImpl o)
Specified by:
compareTo in interface java.lang.Comparable<ElasticImageConfigurationImpl>


Copyright © 2013 Atlassian Software Systems Pty Ltd. All Rights Reserved.