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

software.amazon.awssdk.services.glue.model.CreateDevEndpointResponse Maven / Gradle / Ivy

/*
 * Copyright 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 software.amazon.awssdk.services.glue.model;

import java.time.Instant;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Function;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.ListTrait;
import software.amazon.awssdk.core.traits.LocationTrait;
import software.amazon.awssdk.core.traits.MapTrait;
import software.amazon.awssdk.core.util.DefaultSdkAutoConstructList;
import software.amazon.awssdk.core.util.DefaultSdkAutoConstructMap;
import software.amazon.awssdk.core.util.SdkAutoConstructList;
import software.amazon.awssdk.core.util.SdkAutoConstructMap;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 */
@Generated("software.amazon.awssdk:codegen")
public final class CreateDevEndpointResponse extends GlueResponse implements
        ToCopyableBuilder {
    private static final SdkField ENDPOINT_NAME_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("EndpointName").getter(getter(CreateDevEndpointResponse::endpointName))
            .setter(setter(Builder::endpointName))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("EndpointName").build()).build();

    private static final SdkField STATUS_FIELD = SdkField. builder(MarshallingType.STRING).memberName("Status")
            .getter(getter(CreateDevEndpointResponse::status)).setter(setter(Builder::status))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Status").build()).build();

    private static final SdkField> SECURITY_GROUP_IDS_FIELD = SdkField
            .> builder(MarshallingType.LIST)
            .memberName("SecurityGroupIds")
            .getter(getter(CreateDevEndpointResponse::securityGroupIds))
            .setter(setter(Builder::securityGroupIds))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("SecurityGroupIds").build(),
                    ListTrait
                            .builder()
                            .memberLocationName(null)
                            .memberFieldInfo(
                                    SdkField. builder(MarshallingType.STRING)
                                            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD)
                                                    .locationName("member").build()).build()).build()).build();

    private static final SdkField SUBNET_ID_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("SubnetId").getter(getter(CreateDevEndpointResponse::subnetId)).setter(setter(Builder::subnetId))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("SubnetId").build()).build();

    private static final SdkField ROLE_ARN_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("RoleArn").getter(getter(CreateDevEndpointResponse::roleArn)).setter(setter(Builder::roleArn))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("RoleArn").build()).build();

    private static final SdkField YARN_ENDPOINT_ADDRESS_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("YarnEndpointAddress").getter(getter(CreateDevEndpointResponse::yarnEndpointAddress))
            .setter(setter(Builder::yarnEndpointAddress))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("YarnEndpointAddress").build())
            .build();

    private static final SdkField ZEPPELIN_REMOTE_SPARK_INTERPRETER_PORT_FIELD = SdkField
            . builder(MarshallingType.INTEGER)
            .memberName("ZeppelinRemoteSparkInterpreterPort")
            .getter(getter(CreateDevEndpointResponse::zeppelinRemoteSparkInterpreterPort))
            .setter(setter(Builder::zeppelinRemoteSparkInterpreterPort))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ZeppelinRemoteSparkInterpreterPort")
                    .build()).build();

    private static final SdkField NUMBER_OF_NODES_FIELD = SdkField. builder(MarshallingType.INTEGER)
            .memberName("NumberOfNodes").getter(getter(CreateDevEndpointResponse::numberOfNodes))
            .setter(setter(Builder::numberOfNodes))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("NumberOfNodes").build()).build();

    private static final SdkField WORKER_TYPE_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("WorkerType").getter(getter(CreateDevEndpointResponse::workerTypeAsString))
            .setter(setter(Builder::workerType))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("WorkerType").build()).build();

    private static final SdkField GLUE_VERSION_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("GlueVersion").getter(getter(CreateDevEndpointResponse::glueVersion))
            .setter(setter(Builder::glueVersion))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("GlueVersion").build()).build();

    private static final SdkField NUMBER_OF_WORKERS_FIELD = SdkField. builder(MarshallingType.INTEGER)
            .memberName("NumberOfWorkers").getter(getter(CreateDevEndpointResponse::numberOfWorkers))
            .setter(setter(Builder::numberOfWorkers))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("NumberOfWorkers").build()).build();

    private static final SdkField AVAILABILITY_ZONE_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("AvailabilityZone").getter(getter(CreateDevEndpointResponse::availabilityZone))
            .setter(setter(Builder::availabilityZone))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("AvailabilityZone").build()).build();

    private static final SdkField VPC_ID_FIELD = SdkField. builder(MarshallingType.STRING).memberName("VpcId")
            .getter(getter(CreateDevEndpointResponse::vpcId)).setter(setter(Builder::vpcId))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("VpcId").build()).build();

    private static final SdkField EXTRA_PYTHON_LIBS_S3_PATH_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("ExtraPythonLibsS3Path").getter(getter(CreateDevEndpointResponse::extraPythonLibsS3Path))
            .setter(setter(Builder::extraPythonLibsS3Path))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ExtraPythonLibsS3Path").build())
            .build();

    private static final SdkField EXTRA_JARS_S3_PATH_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("ExtraJarsS3Path").getter(getter(CreateDevEndpointResponse::extraJarsS3Path))
            .setter(setter(Builder::extraJarsS3Path))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ExtraJarsS3Path").build()).build();

    private static final SdkField FAILURE_REASON_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("FailureReason").getter(getter(CreateDevEndpointResponse::failureReason))
            .setter(setter(Builder::failureReason))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("FailureReason").build()).build();

    private static final SdkField SECURITY_CONFIGURATION_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("SecurityConfiguration").getter(getter(CreateDevEndpointResponse::securityConfiguration))
            .setter(setter(Builder::securityConfiguration))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("SecurityConfiguration").build())
            .build();

    private static final SdkField CREATED_TIMESTAMP_FIELD = SdkField. builder(MarshallingType.INSTANT)
            .memberName("CreatedTimestamp").getter(getter(CreateDevEndpointResponse::createdTimestamp))
            .setter(setter(Builder::createdTimestamp))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CreatedTimestamp").build()).build();

    private static final SdkField> ARGUMENTS_FIELD = SdkField
            .> builder(MarshallingType.MAP)
            .memberName("Arguments")
            .getter(getter(CreateDevEndpointResponse::arguments))
            .setter(setter(Builder::arguments))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Arguments").build(),
                    MapTrait.builder()
                            .keyLocationName("key")
                            .valueLocationName("value")
                            .valueFieldInfo(
                                    SdkField. builder(MarshallingType.STRING)
                                            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD)
                                                    .locationName("value").build()).build()).build()).build();

    private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(ENDPOINT_NAME_FIELD,
            STATUS_FIELD, SECURITY_GROUP_IDS_FIELD, SUBNET_ID_FIELD, ROLE_ARN_FIELD, YARN_ENDPOINT_ADDRESS_FIELD,
            ZEPPELIN_REMOTE_SPARK_INTERPRETER_PORT_FIELD, NUMBER_OF_NODES_FIELD, WORKER_TYPE_FIELD, GLUE_VERSION_FIELD,
            NUMBER_OF_WORKERS_FIELD, AVAILABILITY_ZONE_FIELD, VPC_ID_FIELD, EXTRA_PYTHON_LIBS_S3_PATH_FIELD,
            EXTRA_JARS_S3_PATH_FIELD, FAILURE_REASON_FIELD, SECURITY_CONFIGURATION_FIELD, CREATED_TIMESTAMP_FIELD,
            ARGUMENTS_FIELD));

    private final String endpointName;

    private final String status;

    private final List securityGroupIds;

    private final String subnetId;

    private final String roleArn;

    private final String yarnEndpointAddress;

    private final Integer zeppelinRemoteSparkInterpreterPort;

    private final Integer numberOfNodes;

    private final String workerType;

    private final String glueVersion;

    private final Integer numberOfWorkers;

    private final String availabilityZone;

    private final String vpcId;

    private final String extraPythonLibsS3Path;

    private final String extraJarsS3Path;

    private final String failureReason;

    private final String securityConfiguration;

    private final Instant createdTimestamp;

    private final Map arguments;

    private CreateDevEndpointResponse(BuilderImpl builder) {
        super(builder);
        this.endpointName = builder.endpointName;
        this.status = builder.status;
        this.securityGroupIds = builder.securityGroupIds;
        this.subnetId = builder.subnetId;
        this.roleArn = builder.roleArn;
        this.yarnEndpointAddress = builder.yarnEndpointAddress;
        this.zeppelinRemoteSparkInterpreterPort = builder.zeppelinRemoteSparkInterpreterPort;
        this.numberOfNodes = builder.numberOfNodes;
        this.workerType = builder.workerType;
        this.glueVersion = builder.glueVersion;
        this.numberOfWorkers = builder.numberOfWorkers;
        this.availabilityZone = builder.availabilityZone;
        this.vpcId = builder.vpcId;
        this.extraPythonLibsS3Path = builder.extraPythonLibsS3Path;
        this.extraJarsS3Path = builder.extraJarsS3Path;
        this.failureReason = builder.failureReason;
        this.securityConfiguration = builder.securityConfiguration;
        this.createdTimestamp = builder.createdTimestamp;
        this.arguments = builder.arguments;
    }

    /**
     * 

* The name assigned to the new DevEndpoint. *

* * @return The name assigned to the new DevEndpoint. */ public final String endpointName() { return endpointName; } /** *

* The current status of the new DevEndpoint. *

* * @return The current status of the new DevEndpoint. */ public final String status() { return status; } /** * For responses, this returns true if the service returned a value for the SecurityGroupIds property. This DOES NOT * check that the value is non-empty (for which, you should check the {@code isEmpty()} method on the property). * This is useful because the SDK will never return a null collection or map, but you may need to differentiate * between the service returning nothing (or null) and the service returning an empty collection or map. For * requests, this returns true if a value for the property was specified in the request builder, and false if a * value was not specified. */ public final boolean hasSecurityGroupIds() { return securityGroupIds != null && !(securityGroupIds instanceof SdkAutoConstructList); } /** *

* The security groups assigned to the new DevEndpoint. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasSecurityGroupIds} method. *

* * @return The security groups assigned to the new DevEndpoint. */ public final List securityGroupIds() { return securityGroupIds; } /** *

* The subnet ID assigned to the new DevEndpoint. *

* * @return The subnet ID assigned to the new DevEndpoint. */ public final String subnetId() { return subnetId; } /** *

* The Amazon Resource Name (ARN) of the role assigned to the new DevEndpoint. *

* * @return The Amazon Resource Name (ARN) of the role assigned to the new DevEndpoint. */ public final String roleArn() { return roleArn; } /** *

* The address of the YARN endpoint used by this DevEndpoint. *

* * @return The address of the YARN endpoint used by this DevEndpoint. */ public final String yarnEndpointAddress() { return yarnEndpointAddress; } /** *

* The Apache Zeppelin port for the remote Apache Spark interpreter. *

* * @return The Apache Zeppelin port for the remote Apache Spark interpreter. */ public final Integer zeppelinRemoteSparkInterpreterPort() { return zeppelinRemoteSparkInterpreterPort; } /** *

* The number of Glue Data Processing Units (DPUs) allocated to this DevEndpoint. *

* * @return The number of Glue Data Processing Units (DPUs) allocated to this DevEndpoint. */ public final Integer numberOfNodes() { return numberOfNodes; } /** *

* The type of predefined worker that is allocated to the development endpoint. May be a value of Standard, G.1X, or * G.2X. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #workerType} will * return {@link WorkerType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #workerTypeAsString}. *

* * @return The type of predefined worker that is allocated to the development endpoint. May be a value of Standard, * G.1X, or G.2X. * @see WorkerType */ public final WorkerType workerType() { return WorkerType.fromValue(workerType); } /** *

* The type of predefined worker that is allocated to the development endpoint. May be a value of Standard, G.1X, or * G.2X. *

*

* If the service returns an enum value that is not available in the current SDK version, {@link #workerType} will * return {@link WorkerType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #workerTypeAsString}. *

* * @return The type of predefined worker that is allocated to the development endpoint. May be a value of Standard, * G.1X, or G.2X. * @see WorkerType */ public final String workerTypeAsString() { return workerType; } /** *

* Glue version determines the versions of Apache Spark and Python that Glue supports. The Python version indicates * the version supported for running your ETL scripts on development endpoints. *

*

* For more information about the available Glue versions and corresponding Spark and Python versions, see Glue version in the developer guide. *

* * @return Glue version determines the versions of Apache Spark and Python that Glue supports. The Python version * indicates the version supported for running your ETL scripts on development endpoints.

*

* For more information about the available Glue versions and corresponding Spark and Python versions, see * Glue version in the developer * guide. */ public final String glueVersion() { return glueVersion; } /** *

* The number of workers of a defined workerType that are allocated to the development endpoint. *

* * @return The number of workers of a defined workerType that are allocated to the development * endpoint. */ public final Integer numberOfWorkers() { return numberOfWorkers; } /** *

* The Amazon Web Services Availability Zone where this DevEndpoint is located. *

* * @return The Amazon Web Services Availability Zone where this DevEndpoint is located. */ public final String availabilityZone() { return availabilityZone; } /** *

* The ID of the virtual private cloud (VPC) used by this DevEndpoint. *

* * @return The ID of the virtual private cloud (VPC) used by this DevEndpoint. */ public final String vpcId() { return vpcId; } /** *

* The paths to one or more Python libraries in an S3 bucket that will be loaded in your DevEndpoint. *

* * @return The paths to one or more Python libraries in an S3 bucket that will be loaded in your * DevEndpoint. */ public final String extraPythonLibsS3Path() { return extraPythonLibsS3Path; } /** *

* Path to one or more Java .jar files in an S3 bucket that will be loaded in your * DevEndpoint. *

* * @return Path to one or more Java .jar files in an S3 bucket that will be loaded in your * DevEndpoint. */ public final String extraJarsS3Path() { return extraJarsS3Path; } /** *

* The reason for a current failure in this DevEndpoint. *

* * @return The reason for a current failure in this DevEndpoint. */ public final String failureReason() { return failureReason; } /** *

* The name of the SecurityConfiguration structure being used with this DevEndpoint. *

* * @return The name of the SecurityConfiguration structure being used with this * DevEndpoint. */ public final String securityConfiguration() { return securityConfiguration; } /** *

* The point in time at which this DevEndpoint was created. *

* * @return The point in time at which this DevEndpoint was created. */ public final Instant createdTimestamp() { return createdTimestamp; } /** * For responses, this returns true if the service returned a value for the Arguments property. This DOES NOT check * that the value is non-empty (for which, you should check the {@code isEmpty()} method on the property). This is * useful because the SDK will never return a null collection or map, but you may need to differentiate between the * service returning nothing (or null) and the service returning an empty collection or map. For requests, this * returns true if a value for the property was specified in the request builder, and false if a value was not * specified. */ public final boolean hasArguments() { return arguments != null && !(arguments instanceof SdkAutoConstructMap); } /** *

* The map of arguments used to configure this DevEndpoint. *

*

* Valid arguments are: *

*
    *
  • *

    * "--enable-glue-datacatalog": "" *

    *
  • *
*

* You can specify a version of Python support for development endpoints by using the Arguments * parameter in the CreateDevEndpoint or UpdateDevEndpoint APIs. If no arguments are * provided, the version defaults to Python 2. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasArguments} method. *

* * @return The map of arguments used to configure this DevEndpoint.

*

* Valid arguments are: *

*
    *
  • *

    * "--enable-glue-datacatalog": "" *

    *
  • *
*

* You can specify a version of Python support for development endpoints by using the Arguments * parameter in the CreateDevEndpoint or UpdateDevEndpoint APIs. If no arguments * are provided, the version defaults to Python 2. */ public final Map arguments() { return arguments; } @Override public Builder toBuilder() { return new BuilderImpl(this); } public static Builder builder() { return new BuilderImpl(); } public static Class serializableBuilderClass() { return BuilderImpl.class; } @Override public final int hashCode() { int hashCode = 1; hashCode = 31 * hashCode + super.hashCode(); hashCode = 31 * hashCode + Objects.hashCode(endpointName()); hashCode = 31 * hashCode + Objects.hashCode(status()); hashCode = 31 * hashCode + Objects.hashCode(hasSecurityGroupIds() ? securityGroupIds() : null); hashCode = 31 * hashCode + Objects.hashCode(subnetId()); hashCode = 31 * hashCode + Objects.hashCode(roleArn()); hashCode = 31 * hashCode + Objects.hashCode(yarnEndpointAddress()); hashCode = 31 * hashCode + Objects.hashCode(zeppelinRemoteSparkInterpreterPort()); hashCode = 31 * hashCode + Objects.hashCode(numberOfNodes()); hashCode = 31 * hashCode + Objects.hashCode(workerTypeAsString()); hashCode = 31 * hashCode + Objects.hashCode(glueVersion()); hashCode = 31 * hashCode + Objects.hashCode(numberOfWorkers()); hashCode = 31 * hashCode + Objects.hashCode(availabilityZone()); hashCode = 31 * hashCode + Objects.hashCode(vpcId()); hashCode = 31 * hashCode + Objects.hashCode(extraPythonLibsS3Path()); hashCode = 31 * hashCode + Objects.hashCode(extraJarsS3Path()); hashCode = 31 * hashCode + Objects.hashCode(failureReason()); hashCode = 31 * hashCode + Objects.hashCode(securityConfiguration()); hashCode = 31 * hashCode + Objects.hashCode(createdTimestamp()); hashCode = 31 * hashCode + Objects.hashCode(hasArguments() ? arguments() : null); return hashCode; } @Override public final boolean equals(Object obj) { return super.equals(obj) && equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof CreateDevEndpointResponse)) { return false; } CreateDevEndpointResponse other = (CreateDevEndpointResponse) obj; return Objects.equals(endpointName(), other.endpointName()) && Objects.equals(status(), other.status()) && hasSecurityGroupIds() == other.hasSecurityGroupIds() && Objects.equals(securityGroupIds(), other.securityGroupIds()) && Objects.equals(subnetId(), other.subnetId()) && Objects.equals(roleArn(), other.roleArn()) && Objects.equals(yarnEndpointAddress(), other.yarnEndpointAddress()) && Objects.equals(zeppelinRemoteSparkInterpreterPort(), other.zeppelinRemoteSparkInterpreterPort()) && Objects.equals(numberOfNodes(), other.numberOfNodes()) && Objects.equals(workerTypeAsString(), other.workerTypeAsString()) && Objects.equals(glueVersion(), other.glueVersion()) && Objects.equals(numberOfWorkers(), other.numberOfWorkers()) && Objects.equals(availabilityZone(), other.availabilityZone()) && Objects.equals(vpcId(), other.vpcId()) && Objects.equals(extraPythonLibsS3Path(), other.extraPythonLibsS3Path()) && Objects.equals(extraJarsS3Path(), other.extraJarsS3Path()) && Objects.equals(failureReason(), other.failureReason()) && Objects.equals(securityConfiguration(), other.securityConfiguration()) && Objects.equals(createdTimestamp(), other.createdTimestamp()) && hasArguments() == other.hasArguments() && Objects.equals(arguments(), other.arguments()); } /** * 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. */ @Override public final String toString() { return ToString.builder("CreateDevEndpointResponse").add("EndpointName", endpointName()).add("Status", status()) .add("SecurityGroupIds", hasSecurityGroupIds() ? securityGroupIds() : null).add("SubnetId", subnetId()) .add("RoleArn", roleArn()).add("YarnEndpointAddress", yarnEndpointAddress()) .add("ZeppelinRemoteSparkInterpreterPort", zeppelinRemoteSparkInterpreterPort()) .add("NumberOfNodes", numberOfNodes()).add("WorkerType", workerTypeAsString()).add("GlueVersion", glueVersion()) .add("NumberOfWorkers", numberOfWorkers()).add("AvailabilityZone", availabilityZone()).add("VpcId", vpcId()) .add("ExtraPythonLibsS3Path", extraPythonLibsS3Path()).add("ExtraJarsS3Path", extraJarsS3Path()) .add("FailureReason", failureReason()).add("SecurityConfiguration", securityConfiguration()) .add("CreatedTimestamp", createdTimestamp()).add("Arguments", hasArguments() ? arguments() : null).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "EndpointName": return Optional.ofNullable(clazz.cast(endpointName())); case "Status": return Optional.ofNullable(clazz.cast(status())); case "SecurityGroupIds": return Optional.ofNullable(clazz.cast(securityGroupIds())); case "SubnetId": return Optional.ofNullable(clazz.cast(subnetId())); case "RoleArn": return Optional.ofNullable(clazz.cast(roleArn())); case "YarnEndpointAddress": return Optional.ofNullable(clazz.cast(yarnEndpointAddress())); case "ZeppelinRemoteSparkInterpreterPort": return Optional.ofNullable(clazz.cast(zeppelinRemoteSparkInterpreterPort())); case "NumberOfNodes": return Optional.ofNullable(clazz.cast(numberOfNodes())); case "WorkerType": return Optional.ofNullable(clazz.cast(workerTypeAsString())); case "GlueVersion": return Optional.ofNullable(clazz.cast(glueVersion())); case "NumberOfWorkers": return Optional.ofNullable(clazz.cast(numberOfWorkers())); case "AvailabilityZone": return Optional.ofNullable(clazz.cast(availabilityZone())); case "VpcId": return Optional.ofNullable(clazz.cast(vpcId())); case "ExtraPythonLibsS3Path": return Optional.ofNullable(clazz.cast(extraPythonLibsS3Path())); case "ExtraJarsS3Path": return Optional.ofNullable(clazz.cast(extraJarsS3Path())); case "FailureReason": return Optional.ofNullable(clazz.cast(failureReason())); case "SecurityConfiguration": return Optional.ofNullable(clazz.cast(securityConfiguration())); case "CreatedTimestamp": return Optional.ofNullable(clazz.cast(createdTimestamp())); case "Arguments": return Optional.ofNullable(clazz.cast(arguments())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((CreateDevEndpointResponse) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends GlueResponse.Builder, SdkPojo, CopyableBuilder { /** *

* The name assigned to the new DevEndpoint. *

* * @param endpointName * The name assigned to the new DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder endpointName(String endpointName); /** *

* The current status of the new DevEndpoint. *

* * @param status * The current status of the new DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder status(String status); /** *

* The security groups assigned to the new DevEndpoint. *

* * @param securityGroupIds * The security groups assigned to the new DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder securityGroupIds(Collection securityGroupIds); /** *

* The security groups assigned to the new DevEndpoint. *

* * @param securityGroupIds * The security groups assigned to the new DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder securityGroupIds(String... securityGroupIds); /** *

* The subnet ID assigned to the new DevEndpoint. *

* * @param subnetId * The subnet ID assigned to the new DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder subnetId(String subnetId); /** *

* The Amazon Resource Name (ARN) of the role assigned to the new DevEndpoint. *

* * @param roleArn * The Amazon Resource Name (ARN) of the role assigned to the new DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder roleArn(String roleArn); /** *

* The address of the YARN endpoint used by this DevEndpoint. *

* * @param yarnEndpointAddress * The address of the YARN endpoint used by this DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder yarnEndpointAddress(String yarnEndpointAddress); /** *

* The Apache Zeppelin port for the remote Apache Spark interpreter. *

* * @param zeppelinRemoteSparkInterpreterPort * The Apache Zeppelin port for the remote Apache Spark interpreter. * @return Returns a reference to this object so that method calls can be chained together. */ Builder zeppelinRemoteSparkInterpreterPort(Integer zeppelinRemoteSparkInterpreterPort); /** *

* The number of Glue Data Processing Units (DPUs) allocated to this DevEndpoint. *

* * @param numberOfNodes * The number of Glue Data Processing Units (DPUs) allocated to this DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder numberOfNodes(Integer numberOfNodes); /** *

* The type of predefined worker that is allocated to the development endpoint. May be a value of Standard, * G.1X, or G.2X. *

* * @param workerType * The type of predefined worker that is allocated to the development endpoint. May be a value of * Standard, G.1X, or G.2X. * @see WorkerType * @return Returns a reference to this object so that method calls can be chained together. * @see WorkerType */ Builder workerType(String workerType); /** *

* The type of predefined worker that is allocated to the development endpoint. May be a value of Standard, * G.1X, or G.2X. *

* * @param workerType * The type of predefined worker that is allocated to the development endpoint. May be a value of * Standard, G.1X, or G.2X. * @see WorkerType * @return Returns a reference to this object so that method calls can be chained together. * @see WorkerType */ Builder workerType(WorkerType workerType); /** *

* Glue version determines the versions of Apache Spark and Python that Glue supports. The Python version * indicates the version supported for running your ETL scripts on development endpoints. *

*

* For more information about the available Glue versions and corresponding Spark and Python versions, see Glue version in the developer guide. *

* * @param glueVersion * Glue version determines the versions of Apache Spark and Python that Glue supports. The Python version * indicates the version supported for running your ETL scripts on development endpoints.

*

* For more information about the available Glue versions and corresponding Spark and Python versions, * see Glue version in the * developer guide. * @return Returns a reference to this object so that method calls can be chained together. */ Builder glueVersion(String glueVersion); /** *

* The number of workers of a defined workerType that are allocated to the development endpoint. *

* * @param numberOfWorkers * The number of workers of a defined workerType that are allocated to the development * endpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder numberOfWorkers(Integer numberOfWorkers); /** *

* The Amazon Web Services Availability Zone where this DevEndpoint is located. *

* * @param availabilityZone * The Amazon Web Services Availability Zone where this DevEndpoint is located. * @return Returns a reference to this object so that method calls can be chained together. */ Builder availabilityZone(String availabilityZone); /** *

* The ID of the virtual private cloud (VPC) used by this DevEndpoint. *

* * @param vpcId * The ID of the virtual private cloud (VPC) used by this DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder vpcId(String vpcId); /** *

* The paths to one or more Python libraries in an S3 bucket that will be loaded in your * DevEndpoint. *

* * @param extraPythonLibsS3Path * The paths to one or more Python libraries in an S3 bucket that will be loaded in your * DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder extraPythonLibsS3Path(String extraPythonLibsS3Path); /** *

* Path to one or more Java .jar files in an S3 bucket that will be loaded in your * DevEndpoint. *

* * @param extraJarsS3Path * Path to one or more Java .jar files in an S3 bucket that will be loaded in your * DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder extraJarsS3Path(String extraJarsS3Path); /** *

* The reason for a current failure in this DevEndpoint. *

* * @param failureReason * The reason for a current failure in this DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder failureReason(String failureReason); /** *

* The name of the SecurityConfiguration structure being used with this DevEndpoint. *

* * @param securityConfiguration * The name of the SecurityConfiguration structure being used with this * DevEndpoint. * @return Returns a reference to this object so that method calls can be chained together. */ Builder securityConfiguration(String securityConfiguration); /** *

* The point in time at which this DevEndpoint was created. *

* * @param createdTimestamp * The point in time at which this DevEndpoint was created. * @return Returns a reference to this object so that method calls can be chained together. */ Builder createdTimestamp(Instant createdTimestamp); /** *

* The map of arguments used to configure this DevEndpoint. *

*

* Valid arguments are: *

*
    *
  • *

    * "--enable-glue-datacatalog": "" *

    *
  • *
*

* You can specify a version of Python support for development endpoints by using the Arguments * parameter in the CreateDevEndpoint or UpdateDevEndpoint APIs. If no arguments are * provided, the version defaults to Python 2. *

* * @param arguments * The map of arguments used to configure this DevEndpoint.

*

* Valid arguments are: *

*
    *
  • *

    * "--enable-glue-datacatalog": "" *

    *
  • *
*

* You can specify a version of Python support for development endpoints by using the * Arguments parameter in the CreateDevEndpoint or * UpdateDevEndpoint APIs. If no arguments are provided, the version defaults to Python 2. * @return Returns a reference to this object so that method calls can be chained together. */ Builder arguments(Map arguments); } static final class BuilderImpl extends GlueResponse.BuilderImpl implements Builder { private String endpointName; private String status; private List securityGroupIds = DefaultSdkAutoConstructList.getInstance(); private String subnetId; private String roleArn; private String yarnEndpointAddress; private Integer zeppelinRemoteSparkInterpreterPort; private Integer numberOfNodes; private String workerType; private String glueVersion; private Integer numberOfWorkers; private String availabilityZone; private String vpcId; private String extraPythonLibsS3Path; private String extraJarsS3Path; private String failureReason; private String securityConfiguration; private Instant createdTimestamp; private Map arguments = DefaultSdkAutoConstructMap.getInstance(); private BuilderImpl() { } private BuilderImpl(CreateDevEndpointResponse model) { super(model); endpointName(model.endpointName); status(model.status); securityGroupIds(model.securityGroupIds); subnetId(model.subnetId); roleArn(model.roleArn); yarnEndpointAddress(model.yarnEndpointAddress); zeppelinRemoteSparkInterpreterPort(model.zeppelinRemoteSparkInterpreterPort); numberOfNodes(model.numberOfNodes); workerType(model.workerType); glueVersion(model.glueVersion); numberOfWorkers(model.numberOfWorkers); availabilityZone(model.availabilityZone); vpcId(model.vpcId); extraPythonLibsS3Path(model.extraPythonLibsS3Path); extraJarsS3Path(model.extraJarsS3Path); failureReason(model.failureReason); securityConfiguration(model.securityConfiguration); createdTimestamp(model.createdTimestamp); arguments(model.arguments); } public final String getEndpointName() { return endpointName; } public final void setEndpointName(String endpointName) { this.endpointName = endpointName; } @Override public final Builder endpointName(String endpointName) { this.endpointName = endpointName; return this; } public final String getStatus() { return status; } public final void setStatus(String status) { this.status = status; } @Override public final Builder status(String status) { this.status = status; return this; } public final Collection getSecurityGroupIds() { if (securityGroupIds instanceof SdkAutoConstructList) { return null; } return securityGroupIds; } public final void setSecurityGroupIds(Collection securityGroupIds) { this.securityGroupIds = StringListCopier.copy(securityGroupIds); } @Override public final Builder securityGroupIds(Collection securityGroupIds) { this.securityGroupIds = StringListCopier.copy(securityGroupIds); return this; } @Override @SafeVarargs public final Builder securityGroupIds(String... securityGroupIds) { securityGroupIds(Arrays.asList(securityGroupIds)); return this; } public final String getSubnetId() { return subnetId; } public final void setSubnetId(String subnetId) { this.subnetId = subnetId; } @Override public final Builder subnetId(String subnetId) { this.subnetId = subnetId; return this; } public final String getRoleArn() { return roleArn; } public final void setRoleArn(String roleArn) { this.roleArn = roleArn; } @Override public final Builder roleArn(String roleArn) { this.roleArn = roleArn; return this; } public final String getYarnEndpointAddress() { return yarnEndpointAddress; } public final void setYarnEndpointAddress(String yarnEndpointAddress) { this.yarnEndpointAddress = yarnEndpointAddress; } @Override public final Builder yarnEndpointAddress(String yarnEndpointAddress) { this.yarnEndpointAddress = yarnEndpointAddress; return this; } public final Integer getZeppelinRemoteSparkInterpreterPort() { return zeppelinRemoteSparkInterpreterPort; } public final void setZeppelinRemoteSparkInterpreterPort(Integer zeppelinRemoteSparkInterpreterPort) { this.zeppelinRemoteSparkInterpreterPort = zeppelinRemoteSparkInterpreterPort; } @Override public final Builder zeppelinRemoteSparkInterpreterPort(Integer zeppelinRemoteSparkInterpreterPort) { this.zeppelinRemoteSparkInterpreterPort = zeppelinRemoteSparkInterpreterPort; return this; } public final Integer getNumberOfNodes() { return numberOfNodes; } public final void setNumberOfNodes(Integer numberOfNodes) { this.numberOfNodes = numberOfNodes; } @Override public final Builder numberOfNodes(Integer numberOfNodes) { this.numberOfNodes = numberOfNodes; return this; } public final String getWorkerType() { return workerType; } public final void setWorkerType(String workerType) { this.workerType = workerType; } @Override public final Builder workerType(String workerType) { this.workerType = workerType; return this; } @Override public final Builder workerType(WorkerType workerType) { this.workerType(workerType == null ? null : workerType.toString()); return this; } public final String getGlueVersion() { return glueVersion; } public final void setGlueVersion(String glueVersion) { this.glueVersion = glueVersion; } @Override public final Builder glueVersion(String glueVersion) { this.glueVersion = glueVersion; return this; } public final Integer getNumberOfWorkers() { return numberOfWorkers; } public final void setNumberOfWorkers(Integer numberOfWorkers) { this.numberOfWorkers = numberOfWorkers; } @Override public final Builder numberOfWorkers(Integer numberOfWorkers) { this.numberOfWorkers = numberOfWorkers; return this; } public final String getAvailabilityZone() { return availabilityZone; } public final void setAvailabilityZone(String availabilityZone) { this.availabilityZone = availabilityZone; } @Override public final Builder availabilityZone(String availabilityZone) { this.availabilityZone = availabilityZone; return this; } public final String getVpcId() { return vpcId; } public final void setVpcId(String vpcId) { this.vpcId = vpcId; } @Override public final Builder vpcId(String vpcId) { this.vpcId = vpcId; return this; } public final String getExtraPythonLibsS3Path() { return extraPythonLibsS3Path; } public final void setExtraPythonLibsS3Path(String extraPythonLibsS3Path) { this.extraPythonLibsS3Path = extraPythonLibsS3Path; } @Override public final Builder extraPythonLibsS3Path(String extraPythonLibsS3Path) { this.extraPythonLibsS3Path = extraPythonLibsS3Path; return this; } public final String getExtraJarsS3Path() { return extraJarsS3Path; } public final void setExtraJarsS3Path(String extraJarsS3Path) { this.extraJarsS3Path = extraJarsS3Path; } @Override public final Builder extraJarsS3Path(String extraJarsS3Path) { this.extraJarsS3Path = extraJarsS3Path; return this; } public final String getFailureReason() { return failureReason; } public final void setFailureReason(String failureReason) { this.failureReason = failureReason; } @Override public final Builder failureReason(String failureReason) { this.failureReason = failureReason; return this; } public final String getSecurityConfiguration() { return securityConfiguration; } public final void setSecurityConfiguration(String securityConfiguration) { this.securityConfiguration = securityConfiguration; } @Override public final Builder securityConfiguration(String securityConfiguration) { this.securityConfiguration = securityConfiguration; return this; } public final Instant getCreatedTimestamp() { return createdTimestamp; } public final void setCreatedTimestamp(Instant createdTimestamp) { this.createdTimestamp = createdTimestamp; } @Override public final Builder createdTimestamp(Instant createdTimestamp) { this.createdTimestamp = createdTimestamp; return this; } public final Map getArguments() { if (arguments instanceof SdkAutoConstructMap) { return null; } return arguments; } public final void setArguments(Map arguments) { this.arguments = MapValueCopier.copy(arguments); } @Override public final Builder arguments(Map arguments) { this.arguments = MapValueCopier.copy(arguments); return this; } @Override public CreateDevEndpointResponse build() { return new CreateDevEndpointResponse(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy