/* * Copyright 2018-2023 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.emrserverless.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; /** * * @see AWS * API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class CreateApplicationRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The name of the application. *
*/ private String name; /** ** The Amazon EMR release associated with the application. *
*/ private String releaseLabel; /** ** The type of application you want to start, such as Spark or Hive. *
*/ private String type; /** ** The client idempotency token of the application to create. Its value must be unique for each request. *
*/ private String clientToken; /** ** The capacity to initialize when the application is created. *
*/ private java.util.Map* The maximum capacity to allocate when the application is created. This is cumulative across all workers at any * given point in time, not just when an application is created. No new resources will be created once any one of * the defined limits is hit. *
*/ private MaximumAllowedResources maximumCapacity; /** ** The tags assigned to the application. *
*/ private java.util.Map* The configuration for an application to automatically start on job submission. *
*/ private AutoStartConfig autoStartConfiguration; /** ** The configuration for an application to automatically stop after a certain amount of time being idle. *
*/ private AutoStopConfig autoStopConfiguration; /** ** The network configuration for customer VPC connectivity. *
*/ private NetworkConfiguration networkConfiguration; /** ** The CPU architecture of an application. *
*/ private String architecture; /** *
* The image configuration for all worker types. You can either set this parameter or
* imageConfiguration
for each worker type in workerTypeSpecifications
.
*
* The key-value pairs that specify worker type to WorkerTypeSpecificationInput
. This parameter must
* contain all valid worker types for a Spark or Hive application. Valid worker types include Driver
* and Executor
for Spark applications and HiveDriver
and TezTask
for Hive
* applications. You can either set image details in this parameter for each worker type, or in
* imageConfiguration
for all worker types.
*
* The name of the application. *
* * @param name * The name of the application. */ public void setName(String name) { this.name = name; } /** ** The name of the application. *
* * @return The name of the application. */ public String getName() { return this.name; } /** ** The name of the application. *
* * @param name * The name of the application. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withName(String name) { setName(name); return this; } /** ** The Amazon EMR release associated with the application. *
* * @param releaseLabel * The Amazon EMR release associated with the application. */ public void setReleaseLabel(String releaseLabel) { this.releaseLabel = releaseLabel; } /** ** The Amazon EMR release associated with the application. *
* * @return The Amazon EMR release associated with the application. */ public String getReleaseLabel() { return this.releaseLabel; } /** ** The Amazon EMR release associated with the application. *
* * @param releaseLabel * The Amazon EMR release associated with the application. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withReleaseLabel(String releaseLabel) { setReleaseLabel(releaseLabel); return this; } /** ** The type of application you want to start, such as Spark or Hive. *
* * @param type * The type of application you want to start, such as Spark or Hive. */ public void setType(String type) { this.type = type; } /** ** The type of application you want to start, such as Spark or Hive. *
* * @return The type of application you want to start, such as Spark or Hive. */ public String getType() { return this.type; } /** ** The type of application you want to start, such as Spark or Hive. *
* * @param type * The type of application you want to start, such as Spark or Hive. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withType(String type) { setType(type); return this; } /** ** The client idempotency token of the application to create. Its value must be unique for each request. *
* * @param clientToken * The client idempotency token of the application to create. Its value must be unique for each request. */ public void setClientToken(String clientToken) { this.clientToken = clientToken; } /** ** The client idempotency token of the application to create. Its value must be unique for each request. *
* * @return The client idempotency token of the application to create. Its value must be unique for each request. */ public String getClientToken() { return this.clientToken; } /** ** The client idempotency token of the application to create. Its value must be unique for each request. *
* * @param clientToken * The client idempotency token of the application to create. Its value must be unique for each request. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withClientToken(String clientToken) { setClientToken(clientToken); return this; } /** ** The capacity to initialize when the application is created. *
* * @return The capacity to initialize when the application is created. */ public java.util.Map* The capacity to initialize when the application is created. *
* * @param initialCapacity * The capacity to initialize when the application is created. */ public void setInitialCapacity(java.util.Map* The capacity to initialize when the application is created. *
* * @param initialCapacity * The capacity to initialize when the application is created. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withInitialCapacity(java.util.Map* The maximum capacity to allocate when the application is created. This is cumulative across all workers at any * given point in time, not just when an application is created. No new resources will be created once any one of * the defined limits is hit. *
* * @param maximumCapacity * The maximum capacity to allocate when the application is created. This is cumulative across all workers at * any given point in time, not just when an application is created. No new resources will be created once * any one of the defined limits is hit. */ public void setMaximumCapacity(MaximumAllowedResources maximumCapacity) { this.maximumCapacity = maximumCapacity; } /** ** The maximum capacity to allocate when the application is created. This is cumulative across all workers at any * given point in time, not just when an application is created. No new resources will be created once any one of * the defined limits is hit. *
* * @return The maximum capacity to allocate when the application is created. This is cumulative across all workers * at any given point in time, not just when an application is created. No new resources will be created * once any one of the defined limits is hit. */ public MaximumAllowedResources getMaximumCapacity() { return this.maximumCapacity; } /** ** The maximum capacity to allocate when the application is created. This is cumulative across all workers at any * given point in time, not just when an application is created. No new resources will be created once any one of * the defined limits is hit. *
* * @param maximumCapacity * The maximum capacity to allocate when the application is created. This is cumulative across all workers at * any given point in time, not just when an application is created. No new resources will be created once * any one of the defined limits is hit. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withMaximumCapacity(MaximumAllowedResources maximumCapacity) { setMaximumCapacity(maximumCapacity); return this; } /** ** The tags assigned to the application. *
* * @return The tags assigned to the application. */ public java.util.Map* The tags assigned to the application. *
* * @param tags * The tags assigned to the application. */ public void setTags(java.util.Map* The tags assigned to the application. *
* * @param tags * The tags assigned to the application. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withTags(java.util.Map* The configuration for an application to automatically start on job submission. *
* * @param autoStartConfiguration * The configuration for an application to automatically start on job submission. */ public void setAutoStartConfiguration(AutoStartConfig autoStartConfiguration) { this.autoStartConfiguration = autoStartConfiguration; } /** ** The configuration for an application to automatically start on job submission. *
* * @return The configuration for an application to automatically start on job submission. */ public AutoStartConfig getAutoStartConfiguration() { return this.autoStartConfiguration; } /** ** The configuration for an application to automatically start on job submission. *
* * @param autoStartConfiguration * The configuration for an application to automatically start on job submission. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withAutoStartConfiguration(AutoStartConfig autoStartConfiguration) { setAutoStartConfiguration(autoStartConfiguration); return this; } /** ** The configuration for an application to automatically stop after a certain amount of time being idle. *
* * @param autoStopConfiguration * The configuration for an application to automatically stop after a certain amount of time being idle. */ public void setAutoStopConfiguration(AutoStopConfig autoStopConfiguration) { this.autoStopConfiguration = autoStopConfiguration; } /** ** The configuration for an application to automatically stop after a certain amount of time being idle. *
* * @return The configuration for an application to automatically stop after a certain amount of time being idle. */ public AutoStopConfig getAutoStopConfiguration() { return this.autoStopConfiguration; } /** ** The configuration for an application to automatically stop after a certain amount of time being idle. *
* * @param autoStopConfiguration * The configuration for an application to automatically stop after a certain amount of time being idle. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withAutoStopConfiguration(AutoStopConfig autoStopConfiguration) { setAutoStopConfiguration(autoStopConfiguration); return this; } /** ** The network configuration for customer VPC connectivity. *
* * @param networkConfiguration * The network configuration for customer VPC connectivity. */ public void setNetworkConfiguration(NetworkConfiguration networkConfiguration) { this.networkConfiguration = networkConfiguration; } /** ** The network configuration for customer VPC connectivity. *
* * @return The network configuration for customer VPC connectivity. */ public NetworkConfiguration getNetworkConfiguration() { return this.networkConfiguration; } /** ** The network configuration for customer VPC connectivity. *
* * @param networkConfiguration * The network configuration for customer VPC connectivity. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateApplicationRequest withNetworkConfiguration(NetworkConfiguration networkConfiguration) { setNetworkConfiguration(networkConfiguration); return this; } /** ** The CPU architecture of an application. *
* * @param architecture * The CPU architecture of an application. * @see Architecture */ public void setArchitecture(String architecture) { this.architecture = architecture; } /** ** The CPU architecture of an application. *
* * @return The CPU architecture of an application. * @see Architecture */ public String getArchitecture() { return this.architecture; } /** ** The CPU architecture of an application. *
* * @param architecture * The CPU architecture of an application. * @return Returns a reference to this object so that method calls can be chained together. * @see Architecture */ public CreateApplicationRequest withArchitecture(String architecture) { setArchitecture(architecture); return this; } /** ** The CPU architecture of an application. *
* * @param architecture * The CPU architecture of an application. * @return Returns a reference to this object so that method calls can be chained together. * @see Architecture */ public CreateApplicationRequest withArchitecture(Architecture architecture) { this.architecture = architecture.toString(); return this; } /** *
* The image configuration for all worker types. You can either set this parameter or
* imageConfiguration
for each worker type in workerTypeSpecifications
.
*
imageConfiguration
for each worker type in workerTypeSpecifications
.
*/
public void setImageConfiguration(ImageConfigurationInput imageConfiguration) {
this.imageConfiguration = imageConfiguration;
}
/**
*
* The image configuration for all worker types. You can either set this parameter or
* imageConfiguration
for each worker type in workerTypeSpecifications
.
*
imageConfiguration
for each worker type in workerTypeSpecifications
.
*/
public ImageConfigurationInput getImageConfiguration() {
return this.imageConfiguration;
}
/**
*
* The image configuration for all worker types. You can either set this parameter or
* imageConfiguration
for each worker type in workerTypeSpecifications
.
*
imageConfiguration
for each worker type in workerTypeSpecifications
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateApplicationRequest withImageConfiguration(ImageConfigurationInput imageConfiguration) {
setImageConfiguration(imageConfiguration);
return this;
}
/**
*
* The key-value pairs that specify worker type to WorkerTypeSpecificationInput
. This parameter must
* contain all valid worker types for a Spark or Hive application. Valid worker types include Driver
* and Executor
for Spark applications and HiveDriver
and TezTask
for Hive
* applications. You can either set image details in this parameter for each worker type, or in
* imageConfiguration
for all worker types.
*
WorkerTypeSpecificationInput
. This parameter
* must contain all valid worker types for a Spark or Hive application. Valid worker types include
* Driver
and Executor
for Spark applications and HiveDriver
and
* TezTask
for Hive applications. You can either set image details in this parameter for each
* worker type, or in imageConfiguration
for all worker types.
*/
public java.util.Map
* The key-value pairs that specify worker type to WorkerTypeSpecificationInput
. This parameter must
* contain all valid worker types for a Spark or Hive application. Valid worker types include Driver
* and Executor
for Spark applications and HiveDriver
and TezTask
for Hive
* applications. You can either set image details in this parameter for each worker type, or in
* imageConfiguration
for all worker types.
*
WorkerTypeSpecificationInput
. This parameter
* must contain all valid worker types for a Spark or Hive application. Valid worker types include
* Driver
and Executor
for Spark applications and HiveDriver
and
* TezTask
for Hive applications. You can either set image details in this parameter for each
* worker type, or in imageConfiguration
for all worker types.
*/
public void setWorkerTypeSpecifications(java.util.Map
* The key-value pairs that specify worker type to WorkerTypeSpecificationInput
. This parameter must
* contain all valid worker types for a Spark or Hive application. Valid worker types include Driver
* and Executor
for Spark applications and HiveDriver
and TezTask
for Hive
* applications. You can either set image details in this parameter for each worker type, or in
* imageConfiguration
for all worker types.
*
WorkerTypeSpecificationInput
. This parameter
* must contain all valid worker types for a Spark or Hive application. Valid worker types include
* Driver
and Executor
for Spark applications and HiveDriver
and
* TezTask
for Hive applications. You can either set image details in this parameter for each
* worker type, or in imageConfiguration
for all worker types.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateApplicationRequest withWorkerTypeSpecifications(java.util.Map