All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.codedeploy.model.DeploymentGroupInfo.kt Maven / Gradle / Ivy

There is a newer version: 1.3.78
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.codedeploy.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Information about a deployment group.
 */
public class DeploymentGroupInfo private constructor(builder: Builder) {
    /**
     * A list of alarms associated with the deployment group.
     */
    public val alarmConfiguration: aws.sdk.kotlin.services.codedeploy.model.AlarmConfiguration? = builder.alarmConfiguration
    /**
     * The application name.
     */
    public val applicationName: kotlin.String? = builder.applicationName
    /**
     * Information about the automatic rollback configuration associated with the deployment group.
     */
    public val autoRollbackConfiguration: aws.sdk.kotlin.services.codedeploy.model.AutoRollbackConfiguration? = builder.autoRollbackConfiguration
    /**
     * A list of associated Auto Scaling groups.
     */
    public val autoScalingGroups: List? = builder.autoScalingGroups
    /**
     * Information about blue/green deployment options for a deployment group.
     */
    public val blueGreenDeploymentConfiguration: aws.sdk.kotlin.services.codedeploy.model.BlueGreenDeploymentConfiguration? = builder.blueGreenDeploymentConfiguration
    /**
     * The destination platform type for the deployment (`Lambda`, `Server`, or `ECS`).
     */
    public val computePlatform: aws.sdk.kotlin.services.codedeploy.model.ComputePlatform? = builder.computePlatform
    /**
     * The deployment configuration name.
     */
    public val deploymentConfigName: kotlin.String? = builder.deploymentConfigName
    /**
     * The deployment group ID.
     */
    public val deploymentGroupId: kotlin.String? = builder.deploymentGroupId
    /**
     * The deployment group name.
     */
    public val deploymentGroupName: kotlin.String? = builder.deploymentGroupName
    /**
     * Information about the type of deployment, either in-place or blue/green, you want to run and whether to route deployment traffic behind a load balancer.
     */
    public val deploymentStyle: aws.sdk.kotlin.services.codedeploy.model.DeploymentStyle? = builder.deploymentStyle
    /**
     * The Amazon EC2 tags on which to filter. The deployment group includes EC2 instances with any of the specified tags.
     */
    public val ec2TagFilters: List? = builder.ec2TagFilters
    /**
     * Information about groups of tags applied to an Amazon EC2 instance. The deployment group includes only Amazon EC2 instances identified by all of the tag groups. Cannot be used in the same call as ec2TagFilters.
     */
    public val ec2TagSet: aws.sdk.kotlin.services.codedeploy.model.Ec2TagSet? = builder.ec2TagSet
    /**
     * The target Amazon ECS services in the deployment group. This applies only to deployment groups that use the Amazon ECS compute platform. A target Amazon ECS service is specified as an Amazon ECS cluster and service name pair using the format `:`.
     */
    public val ecsServices: List? = builder.ecsServices
    /**
     * Information about the most recent attempted deployment to the deployment group.
     */
    public val lastAttemptedDeployment: aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo? = builder.lastAttemptedDeployment
    /**
     * Information about the most recent successful deployment to the deployment group.
     */
    public val lastSuccessfulDeployment: aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo? = builder.lastSuccessfulDeployment
    /**
     * Information about the load balancer to use in a deployment.
     */
    public val loadBalancerInfo: aws.sdk.kotlin.services.codedeploy.model.LoadBalancerInfo? = builder.loadBalancerInfo
    /**
     * The on-premises instance tags on which to filter. The deployment group includes on-premises instances with any of the specified tags.
     */
    public val onPremisesInstanceTagFilters: List? = builder.onPremisesInstanceTagFilters
    /**
     * Information about groups of tags applied to an on-premises instance. The deployment group includes only on-premises instances identified by all the tag groups. Cannot be used in the same call as onPremisesInstanceTagFilters.
     */
    public val onPremisesTagSet: aws.sdk.kotlin.services.codedeploy.model.OnPremisesTagSet? = builder.onPremisesTagSet
    /**
     * Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.
     *
     * If this option is set to `UPDATE` or is unspecified, CodeDeploy initiates one or more 'auto-update outdated instances' deployments to apply the deployed application revision to the new Amazon EC2 instances.
     *
     * If this option is set to `IGNORE`, CodeDeploy does not initiate a deployment to update the new Amazon EC2 instances. This may result in instances having different revisions.
     */
    public val outdatedInstancesStrategy: aws.sdk.kotlin.services.codedeploy.model.OutdatedInstancesStrategy? = builder.outdatedInstancesStrategy
    /**
     * A service role Amazon Resource Name (ARN) that grants CodeDeploy permission to make calls to Amazon Web Services services on your behalf. For more information, see [Create a Service Role for CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/getting-started-create-service-role.html) in the *CodeDeploy User Guide*.
     */
    public val serviceRoleArn: kotlin.String? = builder.serviceRoleArn
    /**
     * Information about the deployment group's target revision, including type and location.
     */
    public val targetRevision: aws.sdk.kotlin.services.codedeploy.model.RevisionLocation? = builder.targetRevision
    /**
     * Indicates whether the deployment group was configured to have CodeDeploy install a termination hook into an Auto Scaling group.
     *
     * For more information about the termination hook, see [How Amazon EC2 Auto Scaling works with CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-auto-scaling.html#integrations-aws-auto-scaling-behaviors) in the *CodeDeploy User Guide*.
     */
    public val terminationHookEnabled: kotlin.Boolean = builder.terminationHookEnabled
    /**
     * Information about triggers associated with the deployment group.
     */
    public val triggerConfigurations: List? = builder.triggerConfigurations

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codedeploy.model.DeploymentGroupInfo = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("DeploymentGroupInfo(")
        append("alarmConfiguration=$alarmConfiguration,")
        append("applicationName=$applicationName,")
        append("autoRollbackConfiguration=$autoRollbackConfiguration,")
        append("autoScalingGroups=$autoScalingGroups,")
        append("blueGreenDeploymentConfiguration=$blueGreenDeploymentConfiguration,")
        append("computePlatform=$computePlatform,")
        append("deploymentConfigName=$deploymentConfigName,")
        append("deploymentGroupId=$deploymentGroupId,")
        append("deploymentGroupName=$deploymentGroupName,")
        append("deploymentStyle=$deploymentStyle,")
        append("ec2TagFilters=$ec2TagFilters,")
        append("ec2TagSet=$ec2TagSet,")
        append("ecsServices=$ecsServices,")
        append("lastAttemptedDeployment=$lastAttemptedDeployment,")
        append("lastSuccessfulDeployment=$lastSuccessfulDeployment,")
        append("loadBalancerInfo=$loadBalancerInfo,")
        append("onPremisesInstanceTagFilters=$onPremisesInstanceTagFilters,")
        append("onPremisesTagSet=$onPremisesTagSet,")
        append("outdatedInstancesStrategy=$outdatedInstancesStrategy,")
        append("serviceRoleArn=$serviceRoleArn,")
        append("targetRevision=$targetRevision,")
        append("terminationHookEnabled=$terminationHookEnabled,")
        append("triggerConfigurations=$triggerConfigurations")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = alarmConfiguration?.hashCode() ?: 0
        result = 31 * result + (applicationName?.hashCode() ?: 0)
        result = 31 * result + (autoRollbackConfiguration?.hashCode() ?: 0)
        result = 31 * result + (autoScalingGroups?.hashCode() ?: 0)
        result = 31 * result + (blueGreenDeploymentConfiguration?.hashCode() ?: 0)
        result = 31 * result + (computePlatform?.hashCode() ?: 0)
        result = 31 * result + (deploymentConfigName?.hashCode() ?: 0)
        result = 31 * result + (deploymentGroupId?.hashCode() ?: 0)
        result = 31 * result + (deploymentGroupName?.hashCode() ?: 0)
        result = 31 * result + (deploymentStyle?.hashCode() ?: 0)
        result = 31 * result + (ec2TagFilters?.hashCode() ?: 0)
        result = 31 * result + (ec2TagSet?.hashCode() ?: 0)
        result = 31 * result + (ecsServices?.hashCode() ?: 0)
        result = 31 * result + (lastAttemptedDeployment?.hashCode() ?: 0)
        result = 31 * result + (lastSuccessfulDeployment?.hashCode() ?: 0)
        result = 31 * result + (loadBalancerInfo?.hashCode() ?: 0)
        result = 31 * result + (onPremisesInstanceTagFilters?.hashCode() ?: 0)
        result = 31 * result + (onPremisesTagSet?.hashCode() ?: 0)
        result = 31 * result + (outdatedInstancesStrategy?.hashCode() ?: 0)
        result = 31 * result + (serviceRoleArn?.hashCode() ?: 0)
        result = 31 * result + (targetRevision?.hashCode() ?: 0)
        result = 31 * result + (terminationHookEnabled.hashCode())
        result = 31 * result + (triggerConfigurations?.hashCode() ?: 0)
        return result
    }

    override fun equals(other: kotlin.Any?): kotlin.Boolean {
        if (this === other) return true
        if (other == null || this::class != other::class) return false

        other as DeploymentGroupInfo

        if (alarmConfiguration != other.alarmConfiguration) return false
        if (applicationName != other.applicationName) return false
        if (autoRollbackConfiguration != other.autoRollbackConfiguration) return false
        if (autoScalingGroups != other.autoScalingGroups) return false
        if (blueGreenDeploymentConfiguration != other.blueGreenDeploymentConfiguration) return false
        if (computePlatform != other.computePlatform) return false
        if (deploymentConfigName != other.deploymentConfigName) return false
        if (deploymentGroupId != other.deploymentGroupId) return false
        if (deploymentGroupName != other.deploymentGroupName) return false
        if (deploymentStyle != other.deploymentStyle) return false
        if (ec2TagFilters != other.ec2TagFilters) return false
        if (ec2TagSet != other.ec2TagSet) return false
        if (ecsServices != other.ecsServices) return false
        if (lastAttemptedDeployment != other.lastAttemptedDeployment) return false
        if (lastSuccessfulDeployment != other.lastSuccessfulDeployment) return false
        if (loadBalancerInfo != other.loadBalancerInfo) return false
        if (onPremisesInstanceTagFilters != other.onPremisesInstanceTagFilters) return false
        if (onPremisesTagSet != other.onPremisesTagSet) return false
        if (outdatedInstancesStrategy != other.outdatedInstancesStrategy) return false
        if (serviceRoleArn != other.serviceRoleArn) return false
        if (targetRevision != other.targetRevision) return false
        if (terminationHookEnabled != other.terminationHookEnabled) return false
        if (triggerConfigurations != other.triggerConfigurations) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codedeploy.model.DeploymentGroupInfo = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * A list of alarms associated with the deployment group.
         */
        public var alarmConfiguration: aws.sdk.kotlin.services.codedeploy.model.AlarmConfiguration? = null
        /**
         * The application name.
         */
        public var applicationName: kotlin.String? = null
        /**
         * Information about the automatic rollback configuration associated with the deployment group.
         */
        public var autoRollbackConfiguration: aws.sdk.kotlin.services.codedeploy.model.AutoRollbackConfiguration? = null
        /**
         * A list of associated Auto Scaling groups.
         */
        public var autoScalingGroups: List? = null
        /**
         * Information about blue/green deployment options for a deployment group.
         */
        public var blueGreenDeploymentConfiguration: aws.sdk.kotlin.services.codedeploy.model.BlueGreenDeploymentConfiguration? = null
        /**
         * The destination platform type for the deployment (`Lambda`, `Server`, or `ECS`).
         */
        public var computePlatform: aws.sdk.kotlin.services.codedeploy.model.ComputePlatform? = null
        /**
         * The deployment configuration name.
         */
        public var deploymentConfigName: kotlin.String? = null
        /**
         * The deployment group ID.
         */
        public var deploymentGroupId: kotlin.String? = null
        /**
         * The deployment group name.
         */
        public var deploymentGroupName: kotlin.String? = null
        /**
         * Information about the type of deployment, either in-place or blue/green, you want to run and whether to route deployment traffic behind a load balancer.
         */
        public var deploymentStyle: aws.sdk.kotlin.services.codedeploy.model.DeploymentStyle? = null
        /**
         * The Amazon EC2 tags on which to filter. The deployment group includes EC2 instances with any of the specified tags.
         */
        public var ec2TagFilters: List? = null
        /**
         * Information about groups of tags applied to an Amazon EC2 instance. The deployment group includes only Amazon EC2 instances identified by all of the tag groups. Cannot be used in the same call as ec2TagFilters.
         */
        public var ec2TagSet: aws.sdk.kotlin.services.codedeploy.model.Ec2TagSet? = null
        /**
         * The target Amazon ECS services in the deployment group. This applies only to deployment groups that use the Amazon ECS compute platform. A target Amazon ECS service is specified as an Amazon ECS cluster and service name pair using the format `:`.
         */
        public var ecsServices: List? = null
        /**
         * Information about the most recent attempted deployment to the deployment group.
         */
        public var lastAttemptedDeployment: aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo? = null
        /**
         * Information about the most recent successful deployment to the deployment group.
         */
        public var lastSuccessfulDeployment: aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo? = null
        /**
         * Information about the load balancer to use in a deployment.
         */
        public var loadBalancerInfo: aws.sdk.kotlin.services.codedeploy.model.LoadBalancerInfo? = null
        /**
         * The on-premises instance tags on which to filter. The deployment group includes on-premises instances with any of the specified tags.
         */
        public var onPremisesInstanceTagFilters: List? = null
        /**
         * Information about groups of tags applied to an on-premises instance. The deployment group includes only on-premises instances identified by all the tag groups. Cannot be used in the same call as onPremisesInstanceTagFilters.
         */
        public var onPremisesTagSet: aws.sdk.kotlin.services.codedeploy.model.OnPremisesTagSet? = null
        /**
         * Indicates what happens when new Amazon EC2 instances are launched mid-deployment and do not receive the deployed application revision.
         *
         * If this option is set to `UPDATE` or is unspecified, CodeDeploy initiates one or more 'auto-update outdated instances' deployments to apply the deployed application revision to the new Amazon EC2 instances.
         *
         * If this option is set to `IGNORE`, CodeDeploy does not initiate a deployment to update the new Amazon EC2 instances. This may result in instances having different revisions.
         */
        public var outdatedInstancesStrategy: aws.sdk.kotlin.services.codedeploy.model.OutdatedInstancesStrategy? = null
        /**
         * A service role Amazon Resource Name (ARN) that grants CodeDeploy permission to make calls to Amazon Web Services services on your behalf. For more information, see [Create a Service Role for CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/getting-started-create-service-role.html) in the *CodeDeploy User Guide*.
         */
        public var serviceRoleArn: kotlin.String? = null
        /**
         * Information about the deployment group's target revision, including type and location.
         */
        public var targetRevision: aws.sdk.kotlin.services.codedeploy.model.RevisionLocation? = null
        /**
         * Indicates whether the deployment group was configured to have CodeDeploy install a termination hook into an Auto Scaling group.
         *
         * For more information about the termination hook, see [How Amazon EC2 Auto Scaling works with CodeDeploy](https://docs.aws.amazon.com/codedeploy/latest/userguide/integrations-aws-auto-scaling.html#integrations-aws-auto-scaling-behaviors) in the *CodeDeploy User Guide*.
         */
        public var terminationHookEnabled: kotlin.Boolean = false
        /**
         * Information about triggers associated with the deployment group.
         */
        public var triggerConfigurations: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.codedeploy.model.DeploymentGroupInfo) : this() {
            this.alarmConfiguration = x.alarmConfiguration
            this.applicationName = x.applicationName
            this.autoRollbackConfiguration = x.autoRollbackConfiguration
            this.autoScalingGroups = x.autoScalingGroups
            this.blueGreenDeploymentConfiguration = x.blueGreenDeploymentConfiguration
            this.computePlatform = x.computePlatform
            this.deploymentConfigName = x.deploymentConfigName
            this.deploymentGroupId = x.deploymentGroupId
            this.deploymentGroupName = x.deploymentGroupName
            this.deploymentStyle = x.deploymentStyle
            this.ec2TagFilters = x.ec2TagFilters
            this.ec2TagSet = x.ec2TagSet
            this.ecsServices = x.ecsServices
            this.lastAttemptedDeployment = x.lastAttemptedDeployment
            this.lastSuccessfulDeployment = x.lastSuccessfulDeployment
            this.loadBalancerInfo = x.loadBalancerInfo
            this.onPremisesInstanceTagFilters = x.onPremisesInstanceTagFilters
            this.onPremisesTagSet = x.onPremisesTagSet
            this.outdatedInstancesStrategy = x.outdatedInstancesStrategy
            this.serviceRoleArn = x.serviceRoleArn
            this.targetRevision = x.targetRevision
            this.terminationHookEnabled = x.terminationHookEnabled
            this.triggerConfigurations = x.triggerConfigurations
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.codedeploy.model.DeploymentGroupInfo = DeploymentGroupInfo(this)

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.AlarmConfiguration] inside the given [block]
         */
        public fun alarmConfiguration(block: aws.sdk.kotlin.services.codedeploy.model.AlarmConfiguration.Builder.() -> kotlin.Unit) {
            this.alarmConfiguration = aws.sdk.kotlin.services.codedeploy.model.AlarmConfiguration.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.AutoRollbackConfiguration] inside the given [block]
         */
        public fun autoRollbackConfiguration(block: aws.sdk.kotlin.services.codedeploy.model.AutoRollbackConfiguration.Builder.() -> kotlin.Unit) {
            this.autoRollbackConfiguration = aws.sdk.kotlin.services.codedeploy.model.AutoRollbackConfiguration.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.BlueGreenDeploymentConfiguration] inside the given [block]
         */
        public fun blueGreenDeploymentConfiguration(block: aws.sdk.kotlin.services.codedeploy.model.BlueGreenDeploymentConfiguration.Builder.() -> kotlin.Unit) {
            this.blueGreenDeploymentConfiguration = aws.sdk.kotlin.services.codedeploy.model.BlueGreenDeploymentConfiguration.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.DeploymentStyle] inside the given [block]
         */
        public fun deploymentStyle(block: aws.sdk.kotlin.services.codedeploy.model.DeploymentStyle.Builder.() -> kotlin.Unit) {
            this.deploymentStyle = aws.sdk.kotlin.services.codedeploy.model.DeploymentStyle.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.Ec2TagSet] inside the given [block]
         */
        public fun ec2TagSet(block: aws.sdk.kotlin.services.codedeploy.model.Ec2TagSet.Builder.() -> kotlin.Unit) {
            this.ec2TagSet = aws.sdk.kotlin.services.codedeploy.model.Ec2TagSet.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo] inside the given [block]
         */
        public fun lastAttemptedDeployment(block: aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo.Builder.() -> kotlin.Unit) {
            this.lastAttemptedDeployment = aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo] inside the given [block]
         */
        public fun lastSuccessfulDeployment(block: aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo.Builder.() -> kotlin.Unit) {
            this.lastSuccessfulDeployment = aws.sdk.kotlin.services.codedeploy.model.LastDeploymentInfo.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.LoadBalancerInfo] inside the given [block]
         */
        public fun loadBalancerInfo(block: aws.sdk.kotlin.services.codedeploy.model.LoadBalancerInfo.Builder.() -> kotlin.Unit) {
            this.loadBalancerInfo = aws.sdk.kotlin.services.codedeploy.model.LoadBalancerInfo.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.OnPremisesTagSet] inside the given [block]
         */
        public fun onPremisesTagSet(block: aws.sdk.kotlin.services.codedeploy.model.OnPremisesTagSet.Builder.() -> kotlin.Unit) {
            this.onPremisesTagSet = aws.sdk.kotlin.services.codedeploy.model.OnPremisesTagSet.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.codedeploy.model.RevisionLocation] inside the given [block]
         */
        public fun targetRevision(block: aws.sdk.kotlin.services.codedeploy.model.RevisionLocation.Builder.() -> kotlin.Unit) {
            this.targetRevision = aws.sdk.kotlin.services.codedeploy.model.RevisionLocation.invoke(block)
        }

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy