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

com.amazonaws.services.ecs.model.ExecuteCommandConfiguration Maven / Gradle / Ivy

Go to download

The AWS Java SDK for the Amazon EC2 Container Service holds the client classes that are used for communicating with the Amazon EC2 Container Service

There is a newer version: 1.12.780
Show newest version
/*
 * Copyright 2016-2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.ecs.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* The details of the execute command configuration. *

* * @see AWS * API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ExecuteCommandConfiguration implements Serializable, Cloneable, StructuredPojo { /** *

* Specify an AWS Key Management Service key ID to encrypt the data between the local client and the container. *

*/ private String kmsKeyId; /** *

* The log setting to use for redirecting logs for your execute command results. The following log settings are * available. *

*
    *
  • *

    * NONE: The execute command session is not logged. *

    *
  • *
  • *

    * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in the * task definition, the output won't be logged. *

    *
  • *
  • *

    * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

    *
  • *
*/ private String logging; /** *

* The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch Logs or * an Amazon S3 bucket. When logging=OVERRIDE is specified, a logConfiguration must be * provided. *

*/ private ExecuteCommandLogConfiguration logConfiguration; /** *

* Specify an AWS Key Management Service key ID to encrypt the data between the local client and the container. *

* * @param kmsKeyId * Specify an AWS Key Management Service key ID to encrypt the data between the local client and the * container. */ public void setKmsKeyId(String kmsKeyId) { this.kmsKeyId = kmsKeyId; } /** *

* Specify an AWS Key Management Service key ID to encrypt the data between the local client and the container. *

* * @return Specify an AWS Key Management Service key ID to encrypt the data between the local client and the * container. */ public String getKmsKeyId() { return this.kmsKeyId; } /** *

* Specify an AWS Key Management Service key ID to encrypt the data between the local client and the container. *

* * @param kmsKeyId * Specify an AWS Key Management Service key ID to encrypt the data between the local client and the * container. * @return Returns a reference to this object so that method calls can be chained together. */ public ExecuteCommandConfiguration withKmsKeyId(String kmsKeyId) { setKmsKeyId(kmsKeyId); return this; } /** *

* The log setting to use for redirecting logs for your execute command results. The following log settings are * available. *

*
    *
  • *

    * NONE: The execute command session is not logged. *

    *
  • *
  • *

    * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in the * task definition, the output won't be logged. *

    *
  • *
  • *

    * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

    *
  • *
* * @param logging * The log setting to use for redirecting logs for your execute command results. The following log settings * are available.

*
    *
  • *

    * NONE: The execute command session is not logged. *

    *
  • *
  • *

    * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in * the task definition, the output won't be logged. *

    *
  • *
  • *

    * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

    *
  • * @see ExecuteCommandLogging */ public void setLogging(String logging) { this.logging = logging; } /** *

    * The log setting to use for redirecting logs for your execute command results. The following log settings are * available. *

    *
      *
    • *

      * NONE: The execute command session is not logged. *

      *
    • *
    • *

      * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in the * task definition, the output won't be logged. *

      *
    • *
    • *

      * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

      *
    • *
    * * @return The log setting to use for redirecting logs for your execute command results. The following log settings * are available.

    *
      *
    • *

      * NONE: The execute command session is not logged. *

      *
    • *
    • *

      * DEFAULT: The awslogs configuration in the task definition is used. If no * logging parameter is specified, it defaults to this value. If no awslogs log driver is * configured in the task definition, the output won't be logged. *

      *
    • *
    • *

      * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

      *
    • * @see ExecuteCommandLogging */ public String getLogging() { return this.logging; } /** *

      * The log setting to use for redirecting logs for your execute command results. The following log settings are * available. *

      *
        *
      • *

        * NONE: The execute command session is not logged. *

        *
      • *
      • *

        * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in the * task definition, the output won't be logged. *

        *
      • *
      • *

        * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

        *
      • *
      * * @param logging * The log setting to use for redirecting logs for your execute command results. The following log settings * are available.

      *
        *
      • *

        * NONE: The execute command session is not logged. *

        *
      • *
      • *

        * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in * the task definition, the output won't be logged. *

        *
      • *
      • *

        * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

        *
      • * @return Returns a reference to this object so that method calls can be chained together. * @see ExecuteCommandLogging */ public ExecuteCommandConfiguration withLogging(String logging) { setLogging(logging); return this; } /** *

        * The log setting to use for redirecting logs for your execute command results. The following log settings are * available. *

        *
          *
        • *

          * NONE: The execute command session is not logged. *

          *
        • *
        • *

          * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in the * task definition, the output won't be logged. *

          *
        • *
        • *

          * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

          *
        • *
        * * @param logging * The log setting to use for redirecting logs for your execute command results. The following log settings * are available.

        *
          *
        • *

          * NONE: The execute command session is not logged. *

          *
        • *
        • *

          * DEFAULT: The awslogs configuration in the task definition is used. If no logging * parameter is specified, it defaults to this value. If no awslogs log driver is configured in * the task definition, the output won't be logged. *

          *
        • *
        • *

          * OVERRIDE: Specify the logging details as a part of logConfiguration. If the * OVERRIDE logging option is specified, the logConfiguration is required. *

          *
        • * @return Returns a reference to this object so that method calls can be chained together. * @see ExecuteCommandLogging */ public ExecuteCommandConfiguration withLogging(ExecuteCommandLogging logging) { this.logging = logging.toString(); return this; } /** *

          * The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch Logs or * an Amazon S3 bucket. When logging=OVERRIDE is specified, a logConfiguration must be * provided. *

          * * @param logConfiguration * The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch * Logs or an Amazon S3 bucket. When logging=OVERRIDE is specified, a * logConfiguration must be provided. */ public void setLogConfiguration(ExecuteCommandLogConfiguration logConfiguration) { this.logConfiguration = logConfiguration; } /** *

          * The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch Logs or * an Amazon S3 bucket. When logging=OVERRIDE is specified, a logConfiguration must be * provided. *

          * * @return The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch * Logs or an Amazon S3 bucket. When logging=OVERRIDE is specified, a * logConfiguration must be provided. */ public ExecuteCommandLogConfiguration getLogConfiguration() { return this.logConfiguration; } /** *

          * The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch Logs or * an Amazon S3 bucket. When logging=OVERRIDE is specified, a logConfiguration must be * provided. *

          * * @param logConfiguration * The log configuration for the results of the execute command actions. The logs can be sent to CloudWatch * Logs or an Amazon S3 bucket. When logging=OVERRIDE is specified, a * logConfiguration must be provided. * @return Returns a reference to this object so that method calls can be chained together. */ public ExecuteCommandConfiguration withLogConfiguration(ExecuteCommandLogConfiguration logConfiguration) { setLogConfiguration(logConfiguration); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getKmsKeyId() != null) sb.append("KmsKeyId: ").append(getKmsKeyId()).append(","); if (getLogging() != null) sb.append("Logging: ").append(getLogging()).append(","); if (getLogConfiguration() != null) sb.append("LogConfiguration: ").append(getLogConfiguration()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof ExecuteCommandConfiguration == false) return false; ExecuteCommandConfiguration other = (ExecuteCommandConfiguration) obj; if (other.getKmsKeyId() == null ^ this.getKmsKeyId() == null) return false; if (other.getKmsKeyId() != null && other.getKmsKeyId().equals(this.getKmsKeyId()) == false) return false; if (other.getLogging() == null ^ this.getLogging() == null) return false; if (other.getLogging() != null && other.getLogging().equals(this.getLogging()) == false) return false; if (other.getLogConfiguration() == null ^ this.getLogConfiguration() == null) return false; if (other.getLogConfiguration() != null && other.getLogConfiguration().equals(this.getLogConfiguration()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKmsKeyId() == null) ? 0 : getKmsKeyId().hashCode()); hashCode = prime * hashCode + ((getLogging() == null) ? 0 : getLogging().hashCode()); hashCode = prime * hashCode + ((getLogConfiguration() == null) ? 0 : getLogConfiguration().hashCode()); return hashCode; } @Override public ExecuteCommandConfiguration clone() { try { return (ExecuteCommandConfiguration) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.ecs.model.transform.ExecuteCommandConfigurationMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy