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

software.amazon.awssdk.services.neptune.model.ModifyDbClusterRequest Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Neptune module holds the client classes that are used for communicating with Neptune.

There is a newer version: 2.29.39
Show newest version
/*
 * 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.neptune.model;

import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Consumer;
import java.util.function.Function;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.awscore.AwsRequestOverrideConfiguration;
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.util.DefaultSdkAutoConstructList;
import software.amazon.awssdk.core.util.SdkAutoConstructList;
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 ModifyDbClusterRequest extends NeptuneRequest implements
        ToCopyableBuilder {
    private static final SdkField DB_CLUSTER_IDENTIFIER_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("DBClusterIdentifier").getter(getter(ModifyDbClusterRequest::dbClusterIdentifier))
            .setter(setter(Builder::dbClusterIdentifier))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("DBClusterIdentifier").build())
            .build();

    private static final SdkField NEW_DB_CLUSTER_IDENTIFIER_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("NewDBClusterIdentifier").getter(getter(ModifyDbClusterRequest::newDBClusterIdentifier))
            .setter(setter(Builder::newDBClusterIdentifier))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("NewDBClusterIdentifier").build())
            .build();

    private static final SdkField APPLY_IMMEDIATELY_FIELD = SdkField. builder(MarshallingType.BOOLEAN)
            .memberName("ApplyImmediately").getter(getter(ModifyDbClusterRequest::applyImmediately))
            .setter(setter(Builder::applyImmediately))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ApplyImmediately").build()).build();

    private static final SdkField BACKUP_RETENTION_PERIOD_FIELD = SdkField. builder(MarshallingType.INTEGER)
            .memberName("BackupRetentionPeriod").getter(getter(ModifyDbClusterRequest::backupRetentionPeriod))
            .setter(setter(Builder::backupRetentionPeriod))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("BackupRetentionPeriod").build())
            .build();

    private static final SdkField DB_CLUSTER_PARAMETER_GROUP_NAME_FIELD = SdkField
            . builder(MarshallingType.STRING)
            .memberName("DBClusterParameterGroupName")
            .getter(getter(ModifyDbClusterRequest::dbClusterParameterGroupName))
            .setter(setter(Builder::dbClusterParameterGroupName))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("DBClusterParameterGroupName")
                    .build()).build();

    private static final SdkField> VPC_SECURITY_GROUP_IDS_FIELD = SdkField
            .> builder(MarshallingType.LIST)
            .memberName("VpcSecurityGroupIds")
            .getter(getter(ModifyDbClusterRequest::vpcSecurityGroupIds))
            .setter(setter(Builder::vpcSecurityGroupIds))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("VpcSecurityGroupIds").build(),
                    ListTrait
                            .builder()
                            .memberLocationName("VpcSecurityGroupId")
                            .memberFieldInfo(
                                    SdkField. builder(MarshallingType.STRING)
                                            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD)
                                                    .locationName("VpcSecurityGroupId").build()).build()).build()).build();

    private static final SdkField PORT_FIELD = SdkField. builder(MarshallingType.INTEGER).memberName("Port")
            .getter(getter(ModifyDbClusterRequest::port)).setter(setter(Builder::port))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Port").build()).build();

    private static final SdkField MASTER_USER_PASSWORD_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("MasterUserPassword").getter(getter(ModifyDbClusterRequest::masterUserPassword))
            .setter(setter(Builder::masterUserPassword))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("MasterUserPassword").build())
            .build();

    private static final SdkField OPTION_GROUP_NAME_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("OptionGroupName").getter(getter(ModifyDbClusterRequest::optionGroupName))
            .setter(setter(Builder::optionGroupName))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("OptionGroupName").build()).build();

    private static final SdkField PREFERRED_BACKUP_WINDOW_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("PreferredBackupWindow").getter(getter(ModifyDbClusterRequest::preferredBackupWindow))
            .setter(setter(Builder::preferredBackupWindow))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("PreferredBackupWindow").build())
            .build();

    private static final SdkField PREFERRED_MAINTENANCE_WINDOW_FIELD = SdkField
            . builder(MarshallingType.STRING)
            .memberName("PreferredMaintenanceWindow")
            .getter(getter(ModifyDbClusterRequest::preferredMaintenanceWindow))
            .setter(setter(Builder::preferredMaintenanceWindow))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("PreferredMaintenanceWindow").build())
            .build();

    private static final SdkField ENABLE_IAM_DATABASE_AUTHENTICATION_FIELD = SdkField
            . builder(MarshallingType.BOOLEAN)
            .memberName("EnableIAMDatabaseAuthentication")
            .getter(getter(ModifyDbClusterRequest::enableIAMDatabaseAuthentication))
            .setter(setter(Builder::enableIAMDatabaseAuthentication))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("EnableIAMDatabaseAuthentication")
                    .build()).build();

    private static final SdkField CLOUDWATCH_LOGS_EXPORT_CONFIGURATION_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("CloudwatchLogsExportConfiguration")
            .getter(getter(ModifyDbClusterRequest::cloudwatchLogsExportConfiguration))
            .setter(setter(Builder::cloudwatchLogsExportConfiguration))
            .constructor(CloudwatchLogsExportConfiguration::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CloudwatchLogsExportConfiguration")
                    .build()).build();

    private static final SdkField ENGINE_VERSION_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("EngineVersion").getter(getter(ModifyDbClusterRequest::engineVersion))
            .setter(setter(Builder::engineVersion))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("EngineVersion").build()).build();

    private static final SdkField ALLOW_MAJOR_VERSION_UPGRADE_FIELD = SdkField
            . builder(MarshallingType.BOOLEAN).memberName("AllowMajorVersionUpgrade")
            .getter(getter(ModifyDbClusterRequest::allowMajorVersionUpgrade)).setter(setter(Builder::allowMajorVersionUpgrade))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("AllowMajorVersionUpgrade").build())
            .build();

    private static final SdkField DB_INSTANCE_PARAMETER_GROUP_NAME_FIELD = SdkField
            . builder(MarshallingType.STRING)
            .memberName("DBInstanceParameterGroupName")
            .getter(getter(ModifyDbClusterRequest::dbInstanceParameterGroupName))
            .setter(setter(Builder::dbInstanceParameterGroupName))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("DBInstanceParameterGroupName")
                    .build()).build();

    private static final SdkField DELETION_PROTECTION_FIELD = SdkField. builder(MarshallingType.BOOLEAN)
            .memberName("DeletionProtection").getter(getter(ModifyDbClusterRequest::deletionProtection))
            .setter(setter(Builder::deletionProtection))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("DeletionProtection").build())
            .build();

    private static final SdkField COPY_TAGS_TO_SNAPSHOT_FIELD = SdkField. builder(MarshallingType.BOOLEAN)
            .memberName("CopyTagsToSnapshot").getter(getter(ModifyDbClusterRequest::copyTagsToSnapshot))
            .setter(setter(Builder::copyTagsToSnapshot))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CopyTagsToSnapshot").build())
            .build();

    private static final SdkField SERVERLESS_V2_SCALING_CONFIGURATION_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("ServerlessV2ScalingConfiguration")
            .getter(getter(ModifyDbClusterRequest::serverlessV2ScalingConfiguration))
            .setter(setter(Builder::serverlessV2ScalingConfiguration))
            .constructor(ServerlessV2ScalingConfiguration::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ServerlessV2ScalingConfiguration")
                    .build()).build();

    private static final SdkField STORAGE_TYPE_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("StorageType").getter(getter(ModifyDbClusterRequest::storageType)).setter(setter(Builder::storageType))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("StorageType").build()).build();

    private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(DB_CLUSTER_IDENTIFIER_FIELD,
            NEW_DB_CLUSTER_IDENTIFIER_FIELD, APPLY_IMMEDIATELY_FIELD, BACKUP_RETENTION_PERIOD_FIELD,
            DB_CLUSTER_PARAMETER_GROUP_NAME_FIELD, VPC_SECURITY_GROUP_IDS_FIELD, PORT_FIELD, MASTER_USER_PASSWORD_FIELD,
            OPTION_GROUP_NAME_FIELD, PREFERRED_BACKUP_WINDOW_FIELD, PREFERRED_MAINTENANCE_WINDOW_FIELD,
            ENABLE_IAM_DATABASE_AUTHENTICATION_FIELD, CLOUDWATCH_LOGS_EXPORT_CONFIGURATION_FIELD, ENGINE_VERSION_FIELD,
            ALLOW_MAJOR_VERSION_UPGRADE_FIELD, DB_INSTANCE_PARAMETER_GROUP_NAME_FIELD, DELETION_PROTECTION_FIELD,
            COPY_TAGS_TO_SNAPSHOT_FIELD, SERVERLESS_V2_SCALING_CONFIGURATION_FIELD, STORAGE_TYPE_FIELD));

    private final String dbClusterIdentifier;

    private final String newDBClusterIdentifier;

    private final Boolean applyImmediately;

    private final Integer backupRetentionPeriod;

    private final String dbClusterParameterGroupName;

    private final List vpcSecurityGroupIds;

    private final Integer port;

    private final String masterUserPassword;

    private final String optionGroupName;

    private final String preferredBackupWindow;

    private final String preferredMaintenanceWindow;

    private final Boolean enableIAMDatabaseAuthentication;

    private final CloudwatchLogsExportConfiguration cloudwatchLogsExportConfiguration;

    private final String engineVersion;

    private final Boolean allowMajorVersionUpgrade;

    private final String dbInstanceParameterGroupName;

    private final Boolean deletionProtection;

    private final Boolean copyTagsToSnapshot;

    private final ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration;

    private final String storageType;

    private ModifyDbClusterRequest(BuilderImpl builder) {
        super(builder);
        this.dbClusterIdentifier = builder.dbClusterIdentifier;
        this.newDBClusterIdentifier = builder.newDBClusterIdentifier;
        this.applyImmediately = builder.applyImmediately;
        this.backupRetentionPeriod = builder.backupRetentionPeriod;
        this.dbClusterParameterGroupName = builder.dbClusterParameterGroupName;
        this.vpcSecurityGroupIds = builder.vpcSecurityGroupIds;
        this.port = builder.port;
        this.masterUserPassword = builder.masterUserPassword;
        this.optionGroupName = builder.optionGroupName;
        this.preferredBackupWindow = builder.preferredBackupWindow;
        this.preferredMaintenanceWindow = builder.preferredMaintenanceWindow;
        this.enableIAMDatabaseAuthentication = builder.enableIAMDatabaseAuthentication;
        this.cloudwatchLogsExportConfiguration = builder.cloudwatchLogsExportConfiguration;
        this.engineVersion = builder.engineVersion;
        this.allowMajorVersionUpgrade = builder.allowMajorVersionUpgrade;
        this.dbInstanceParameterGroupName = builder.dbInstanceParameterGroupName;
        this.deletionProtection = builder.deletionProtection;
        this.copyTagsToSnapshot = builder.copyTagsToSnapshot;
        this.serverlessV2ScalingConfiguration = builder.serverlessV2ScalingConfiguration;
        this.storageType = builder.storageType;
    }

    /**
     * 

* The DB cluster identifier for the cluster being modified. This parameter is not case-sensitive. *

*

* Constraints: *

*
    *
  • *

    * Must match the identifier of an existing DBCluster. *

    *
  • *
* * @return The DB cluster identifier for the cluster being modified. This parameter is not case-sensitive.

*

* Constraints: *

*
    *
  • *

    * Must match the identifier of an existing DBCluster. *

    *
  • */ public final String dbClusterIdentifier() { return dbClusterIdentifier; } /** *

    * The new DB cluster identifier for the DB cluster when renaming a DB cluster. This value is stored as a lowercase * string. *

    *

    * Constraints: *

    *
      *
    • *

      * Must contain from 1 to 63 letters, numbers, or hyphens *

      *
    • *
    • *

      * The first character must be a letter *

      *
    • *
    • *

      * Cannot end with a hyphen or contain two consecutive hyphens *

      *
    • *
    *

    * Example: my-cluster2 *

    * * @return The new DB cluster identifier for the DB cluster when renaming a DB cluster. This value is stored as a * lowercase string.

    *

    * Constraints: *

    *
      *
    • *

      * Must contain from 1 to 63 letters, numbers, or hyphens *

      *
    • *
    • *

      * The first character must be a letter *

      *
    • *
    • *

      * Cannot end with a hyphen or contain two consecutive hyphens *

      *
    • *
    *

    * Example: my-cluster2 */ public final String newDBClusterIdentifier() { return newDBClusterIdentifier; } /** *

    * A value that specifies whether the modifications in this request and any pending modifications are asynchronously * applied as soon as possible, regardless of the PreferredMaintenanceWindow setting for the DB * cluster. If this parameter is set to false, changes to the DB cluster are applied during the next * maintenance window. *

    *

    * The ApplyImmediately parameter only affects NewDBClusterIdentifier values. If you set * the ApplyImmediately parameter value to false, then changes to NewDBClusterIdentifier * values are applied during the next maintenance window. All other changes are applied immediately, regardless of * the value of the ApplyImmediately parameter. *

    *

    * Default: false *

    * * @return A value that specifies whether the modifications in this request and any pending modifications are * asynchronously applied as soon as possible, regardless of the PreferredMaintenanceWindow * setting for the DB cluster. If this parameter is set to false, changes to the DB cluster are * applied during the next maintenance window.

    *

    * The ApplyImmediately parameter only affects NewDBClusterIdentifier values. If * you set the ApplyImmediately parameter value to false, then changes to * NewDBClusterIdentifier values are applied during the next maintenance window. All other * changes are applied immediately, regardless of the value of the ApplyImmediately parameter. *

    *

    * Default: false */ public final Boolean applyImmediately() { return applyImmediately; } /** *

    * The number of days for which automated backups are retained. You must specify a minimum value of 1. *

    *

    * Default: 1 *

    *

    * Constraints: *

    *
      *
    • *

      * Must be a value from 1 to 35 *

      *
    • *
    * * @return The number of days for which automated backups are retained. You must specify a minimum value of 1.

    *

    * Default: 1 *

    *

    * Constraints: *

    *
      *
    • *

      * Must be a value from 1 to 35 *

      *
    • */ public final Integer backupRetentionPeriod() { return backupRetentionPeriod; } /** *

      * The name of the DB cluster parameter group to use for the DB cluster. *

      * * @return The name of the DB cluster parameter group to use for the DB cluster. */ public final String dbClusterParameterGroupName() { return dbClusterParameterGroupName; } /** * For responses, this returns true if the service returned a value for the VpcSecurityGroupIds 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 hasVpcSecurityGroupIds() { return vpcSecurityGroupIds != null && !(vpcSecurityGroupIds instanceof SdkAutoConstructList); } /** *

      * A list of VPC security groups that the DB cluster will belong to. *

      *

      * 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 #hasVpcSecurityGroupIds} method. *

      * * @return A list of VPC security groups that the DB cluster will belong to. */ public final List vpcSecurityGroupIds() { return vpcSecurityGroupIds; } /** *

      * The port number on which the DB cluster accepts connections. *

      *

      * Constraints: Value must be 1150-65535 *

      *

      * Default: The same port as the original DB cluster. *

      * * @return The port number on which the DB cluster accepts connections.

      *

      * Constraints: Value must be 1150-65535 *

      *

      * Default: The same port as the original DB cluster. */ public final Integer port() { return port; } /** *

      * Not supported by Neptune. *

      * * @return Not supported by Neptune. */ public final String masterUserPassword() { return masterUserPassword; } /** *

      * Not supported by Neptune. *

      * * @return Not supported by Neptune. */ public final String optionGroupName() { return optionGroupName; } /** *

      * The daily time range during which automated backups are created if automated backups are enabled, using the * BackupRetentionPeriod parameter. *

      *

      * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Region. *

      *

      * Constraints: *

      *
        *
      • *

        * Must be in the format hh24:mi-hh24:mi. *

        *
      • *
      • *

        * Must be in Universal Coordinated Time (UTC). *

        *
      • *
      • *

        * Must not conflict with the preferred maintenance window. *

        *
      • *
      • *

        * Must be at least 30 minutes. *

        *
      • *
      * * @return The daily time range during which automated backups are created if automated backups are enabled, using * the BackupRetentionPeriod parameter.

      *

      * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Region. *

      *

      * Constraints: *

      *
        *
      • *

        * Must be in the format hh24:mi-hh24:mi. *

        *
      • *
      • *

        * Must be in Universal Coordinated Time (UTC). *

        *
      • *
      • *

        * Must not conflict with the preferred maintenance window. *

        *
      • *
      • *

        * Must be at least 30 minutes. *

        *
      • */ public final String preferredBackupWindow() { return preferredBackupWindow; } /** *

        * The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC). *

        *

        * Format: ddd:hh24:mi-ddd:hh24:mi *

        *

        * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Region, * occurring on a random day of the week. *

        *

        * Valid Days: Mon, Tue, Wed, Thu, Fri, Sat, Sun. *

        *

        * Constraints: Minimum 30-minute window. *

        * * @return The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).

        *

        * Format: ddd:hh24:mi-ddd:hh24:mi *

        *

        * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Region, * occurring on a random day of the week. *

        *

        * Valid Days: Mon, Tue, Wed, Thu, Fri, Sat, Sun. *

        *

        * Constraints: Minimum 30-minute window. */ public final String preferredMaintenanceWindow() { return preferredMaintenanceWindow; } /** *

        * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and * otherwise false. *

        *

        * Default: false *

        * * @return True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and * otherwise false.

        *

        * Default: false */ public final Boolean enableIAMDatabaseAuthentication() { return enableIAMDatabaseAuthentication; } /** *

        * The configuration setting for the log types to be enabled for export to CloudWatch Logs for a specific DB * cluster. See Using the * CLI to publish Neptune audit logs to CloudWatch Logs. *

        * * @return The configuration setting for the log types to be enabled for export to CloudWatch Logs for a specific DB * cluster. See Using the CLI to publish Neptune audit logs to CloudWatch Logs. */ public final CloudwatchLogsExportConfiguration cloudwatchLogsExportConfiguration() { return cloudwatchLogsExportConfiguration; } /** *

        * The version number of the database engine to which you want to upgrade. Changing this parameter results in an * outage. The change is applied during the next maintenance window unless the ApplyImmediately * parameter is set to true. *

        *

        * For a list of valid engine versions, see Engine Releases for Amazon * Neptune, or call DescribeDBEngineVersions. *

        * * @return The version number of the database engine to which you want to upgrade. Changing this parameter results * in an outage. The change is applied during the next maintenance window unless the * ApplyImmediately parameter is set to true.

        *

        * For a list of valid engine versions, see Engine Releases for * Amazon Neptune, or call DescribeDBEngineVersions. */ public final String engineVersion() { return engineVersion; } /** *

        * A value that indicates whether upgrades between different major versions are allowed. *

        *

        * Constraints: You must set the allow-major-version-upgrade flag when providing an EngineVersion * parameter that uses a different major version than the DB cluster's current version. *

        * * @return A value that indicates whether upgrades between different major versions are allowed.

        *

        * Constraints: You must set the allow-major-version-upgrade flag when providing an * EngineVersion parameter that uses a different major version than the DB cluster's current * version. */ public final Boolean allowMajorVersionUpgrade() { return allowMajorVersionUpgrade; } /** *

        * The name of the DB parameter group to apply to all instances of the DB cluster. *

        * *

        * When you apply a parameter group using DBInstanceParameterGroupName, parameter changes aren't * applied during the next maintenance window but instead are applied immediately. *

        *
        *

        * Default: The existing name setting *

        *

        * Constraints: *

        *
          *
        • *

          * The DB parameter group must be in the same DB parameter group family as the target DB cluster version. *

          *
        • *
        • *

          * The DBInstanceParameterGroupName parameter is only valid in combination with the * AllowMajorVersionUpgrade parameter. *

          *
        • *
        * * @return The name of the DB parameter group to apply to all instances of the DB cluster.

        *

        * When you apply a parameter group using DBInstanceParameterGroupName, parameter changes * aren't applied during the next maintenance window but instead are applied immediately. *

        *
        *

        * Default: The existing name setting *

        *

        * Constraints: *

        *
          *
        • *

          * The DB parameter group must be in the same DB parameter group family as the target DB cluster version. *

          *
        • *
        • *

          * The DBInstanceParameterGroupName parameter is only valid in combination with the * AllowMajorVersionUpgrade parameter. *

          *
        • */ public final String dbInstanceParameterGroupName() { return dbInstanceParameterGroupName; } /** *

          * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when * deletion protection is enabled. By default, deletion protection is disabled. *

          * * @return A value that indicates whether the DB cluster has deletion protection enabled. The database can't be * deleted when deletion protection is enabled. By default, deletion protection is disabled. */ public final Boolean deletionProtection() { return deletionProtection; } /** *

          * If set to true, tags are copied to any snapshot of the DB cluster that is created. *

          * * @return If set to true, tags are copied to any snapshot of the DB cluster that is created. */ public final Boolean copyTagsToSnapshot() { return copyTagsToSnapshot; } /** *

          * Contains the scaling configuration of a Neptune Serverless DB cluster. *

          *

          * For more information, see Using Amazon Neptune * Serverless in the Amazon Neptune User Guide. *

          * * @return Contains the scaling configuration of a Neptune Serverless DB cluster.

          *

          * For more information, see Using Amazon * Neptune Serverless in the Amazon Neptune User Guide. */ public final ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration() { return serverlessV2ScalingConfiguration; } /** *

          * The storage type to associate with the DB cluster. *

          *

          * Valid Values: *

          *
            *
          • *

            * standard | iopt1 *

            *
          • *
          *

          * Default: *

          *
            *
          • *

            * standard *

            *
          • *
          * * @return The storage type to associate with the DB cluster.

          *

          * Valid Values: *

          *
            *
          • *

            * standard | iopt1 *

            *
          • *
          *

          * Default: *

          *
            *
          • *

            * standard *

            *
          • */ public final String storageType() { return storageType; } @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(dbClusterIdentifier()); hashCode = 31 * hashCode + Objects.hashCode(newDBClusterIdentifier()); hashCode = 31 * hashCode + Objects.hashCode(applyImmediately()); hashCode = 31 * hashCode + Objects.hashCode(backupRetentionPeriod()); hashCode = 31 * hashCode + Objects.hashCode(dbClusterParameterGroupName()); hashCode = 31 * hashCode + Objects.hashCode(hasVpcSecurityGroupIds() ? vpcSecurityGroupIds() : null); hashCode = 31 * hashCode + Objects.hashCode(port()); hashCode = 31 * hashCode + Objects.hashCode(masterUserPassword()); hashCode = 31 * hashCode + Objects.hashCode(optionGroupName()); hashCode = 31 * hashCode + Objects.hashCode(preferredBackupWindow()); hashCode = 31 * hashCode + Objects.hashCode(preferredMaintenanceWindow()); hashCode = 31 * hashCode + Objects.hashCode(enableIAMDatabaseAuthentication()); hashCode = 31 * hashCode + Objects.hashCode(cloudwatchLogsExportConfiguration()); hashCode = 31 * hashCode + Objects.hashCode(engineVersion()); hashCode = 31 * hashCode + Objects.hashCode(allowMajorVersionUpgrade()); hashCode = 31 * hashCode + Objects.hashCode(dbInstanceParameterGroupName()); hashCode = 31 * hashCode + Objects.hashCode(deletionProtection()); hashCode = 31 * hashCode + Objects.hashCode(copyTagsToSnapshot()); hashCode = 31 * hashCode + Objects.hashCode(serverlessV2ScalingConfiguration()); hashCode = 31 * hashCode + Objects.hashCode(storageType()); 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 ModifyDbClusterRequest)) { return false; } ModifyDbClusterRequest other = (ModifyDbClusterRequest) obj; return Objects.equals(dbClusterIdentifier(), other.dbClusterIdentifier()) && Objects.equals(newDBClusterIdentifier(), other.newDBClusterIdentifier()) && Objects.equals(applyImmediately(), other.applyImmediately()) && Objects.equals(backupRetentionPeriod(), other.backupRetentionPeriod()) && Objects.equals(dbClusterParameterGroupName(), other.dbClusterParameterGroupName()) && hasVpcSecurityGroupIds() == other.hasVpcSecurityGroupIds() && Objects.equals(vpcSecurityGroupIds(), other.vpcSecurityGroupIds()) && Objects.equals(port(), other.port()) && Objects.equals(masterUserPassword(), other.masterUserPassword()) && Objects.equals(optionGroupName(), other.optionGroupName()) && Objects.equals(preferredBackupWindow(), other.preferredBackupWindow()) && Objects.equals(preferredMaintenanceWindow(), other.preferredMaintenanceWindow()) && Objects.equals(enableIAMDatabaseAuthentication(), other.enableIAMDatabaseAuthentication()) && Objects.equals(cloudwatchLogsExportConfiguration(), other.cloudwatchLogsExportConfiguration()) && Objects.equals(engineVersion(), other.engineVersion()) && Objects.equals(allowMajorVersionUpgrade(), other.allowMajorVersionUpgrade()) && Objects.equals(dbInstanceParameterGroupName(), other.dbInstanceParameterGroupName()) && Objects.equals(deletionProtection(), other.deletionProtection()) && Objects.equals(copyTagsToSnapshot(), other.copyTagsToSnapshot()) && Objects.equals(serverlessV2ScalingConfiguration(), other.serverlessV2ScalingConfiguration()) && Objects.equals(storageType(), other.storageType()); } /** * 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("ModifyDbClusterRequest").add("DBClusterIdentifier", dbClusterIdentifier()) .add("NewDBClusterIdentifier", newDBClusterIdentifier()).add("ApplyImmediately", applyImmediately()) .add("BackupRetentionPeriod", backupRetentionPeriod()) .add("DBClusterParameterGroupName", dbClusterParameterGroupName()) .add("VpcSecurityGroupIds", hasVpcSecurityGroupIds() ? vpcSecurityGroupIds() : null).add("Port", port()) .add("MasterUserPassword", masterUserPassword()).add("OptionGroupName", optionGroupName()) .add("PreferredBackupWindow", preferredBackupWindow()) .add("PreferredMaintenanceWindow", preferredMaintenanceWindow()) .add("EnableIAMDatabaseAuthentication", enableIAMDatabaseAuthentication()) .add("CloudwatchLogsExportConfiguration", cloudwatchLogsExportConfiguration()) .add("EngineVersion", engineVersion()).add("AllowMajorVersionUpgrade", allowMajorVersionUpgrade()) .add("DBInstanceParameterGroupName", dbInstanceParameterGroupName()) .add("DeletionProtection", deletionProtection()).add("CopyTagsToSnapshot", copyTagsToSnapshot()) .add("ServerlessV2ScalingConfiguration", serverlessV2ScalingConfiguration()).add("StorageType", storageType()) .build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "DBClusterIdentifier": return Optional.ofNullable(clazz.cast(dbClusterIdentifier())); case "NewDBClusterIdentifier": return Optional.ofNullable(clazz.cast(newDBClusterIdentifier())); case "ApplyImmediately": return Optional.ofNullable(clazz.cast(applyImmediately())); case "BackupRetentionPeriod": return Optional.ofNullable(clazz.cast(backupRetentionPeriod())); case "DBClusterParameterGroupName": return Optional.ofNullable(clazz.cast(dbClusterParameterGroupName())); case "VpcSecurityGroupIds": return Optional.ofNullable(clazz.cast(vpcSecurityGroupIds())); case "Port": return Optional.ofNullable(clazz.cast(port())); case "MasterUserPassword": return Optional.ofNullable(clazz.cast(masterUserPassword())); case "OptionGroupName": return Optional.ofNullable(clazz.cast(optionGroupName())); case "PreferredBackupWindow": return Optional.ofNullable(clazz.cast(preferredBackupWindow())); case "PreferredMaintenanceWindow": return Optional.ofNullable(clazz.cast(preferredMaintenanceWindow())); case "EnableIAMDatabaseAuthentication": return Optional.ofNullable(clazz.cast(enableIAMDatabaseAuthentication())); case "CloudwatchLogsExportConfiguration": return Optional.ofNullable(clazz.cast(cloudwatchLogsExportConfiguration())); case "EngineVersion": return Optional.ofNullable(clazz.cast(engineVersion())); case "AllowMajorVersionUpgrade": return Optional.ofNullable(clazz.cast(allowMajorVersionUpgrade())); case "DBInstanceParameterGroupName": return Optional.ofNullable(clazz.cast(dbInstanceParameterGroupName())); case "DeletionProtection": return Optional.ofNullable(clazz.cast(deletionProtection())); case "CopyTagsToSnapshot": return Optional.ofNullable(clazz.cast(copyTagsToSnapshot())); case "ServerlessV2ScalingConfiguration": return Optional.ofNullable(clazz.cast(serverlessV2ScalingConfiguration())); case "StorageType": return Optional.ofNullable(clazz.cast(storageType())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((ModifyDbClusterRequest) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends NeptuneRequest.Builder, SdkPojo, CopyableBuilder { /** *

            * The DB cluster identifier for the cluster being modified. This parameter is not case-sensitive. *

            *

            * Constraints: *

            *
              *
            • *

              * Must match the identifier of an existing DBCluster. *

              *
            • *
            * * @param dbClusterIdentifier * The DB cluster identifier for the cluster being modified. This parameter is not case-sensitive.

            *

            * Constraints: *

            *
              *
            • *

              * Must match the identifier of an existing DBCluster. *

              *
            • * @return Returns a reference to this object so that method calls can be chained together. */ Builder dbClusterIdentifier(String dbClusterIdentifier); /** *

              * The new DB cluster identifier for the DB cluster when renaming a DB cluster. This value is stored as a * lowercase string. *

              *

              * Constraints: *

              *
                *
              • *

                * Must contain from 1 to 63 letters, numbers, or hyphens *

                *
              • *
              • *

                * The first character must be a letter *

                *
              • *
              • *

                * Cannot end with a hyphen or contain two consecutive hyphens *

                *
              • *
              *

              * Example: my-cluster2 *

              * * @param newDBClusterIdentifier * The new DB cluster identifier for the DB cluster when renaming a DB cluster. This value is stored as a * lowercase string.

              *

              * Constraints: *

              *
                *
              • *

                * Must contain from 1 to 63 letters, numbers, or hyphens *

                *
              • *
              • *

                * The first character must be a letter *

                *
              • *
              • *

                * Cannot end with a hyphen or contain two consecutive hyphens *

                *
              • *
              *

              * Example: my-cluster2 * @return Returns a reference to this object so that method calls can be chained together. */ Builder newDBClusterIdentifier(String newDBClusterIdentifier); /** *

              * A value that specifies whether the modifications in this request and any pending modifications are * asynchronously applied as soon as possible, regardless of the PreferredMaintenanceWindow setting * for the DB cluster. If this parameter is set to false, changes to the DB cluster are applied * during the next maintenance window. *

              *

              * The ApplyImmediately parameter only affects NewDBClusterIdentifier values. If you * set the ApplyImmediately parameter value to false, then changes to * NewDBClusterIdentifier values are applied during the next maintenance window. All other changes * are applied immediately, regardless of the value of the ApplyImmediately parameter. *

              *

              * Default: false *

              * * @param applyImmediately * A value that specifies whether the modifications in this request and any pending modifications are * asynchronously applied as soon as possible, regardless of the PreferredMaintenanceWindow * setting for the DB cluster. If this parameter is set to false, changes to the DB cluster * are applied during the next maintenance window.

              *

              * The ApplyImmediately parameter only affects NewDBClusterIdentifier values. * If you set the ApplyImmediately parameter value to false, then changes to * NewDBClusterIdentifier values are applied during the next maintenance window. All other * changes are applied immediately, regardless of the value of the ApplyImmediately * parameter. *

              *

              * Default: false * @return Returns a reference to this object so that method calls can be chained together. */ Builder applyImmediately(Boolean applyImmediately); /** *

              * The number of days for which automated backups are retained. You must specify a minimum value of 1. *

              *

              * Default: 1 *

              *

              * Constraints: *

              *
                *
              • *

                * Must be a value from 1 to 35 *

                *
              • *
              * * @param backupRetentionPeriod * The number of days for which automated backups are retained. You must specify a minimum value of * 1.

              *

              * Default: 1 *

              *

              * Constraints: *

              *
                *
              • *

                * Must be a value from 1 to 35 *

                *
              • * @return Returns a reference to this object so that method calls can be chained together. */ Builder backupRetentionPeriod(Integer backupRetentionPeriod); /** *

                * The name of the DB cluster parameter group to use for the DB cluster. *

                * * @param dbClusterParameterGroupName * The name of the DB cluster parameter group to use for the DB cluster. * @return Returns a reference to this object so that method calls can be chained together. */ Builder dbClusterParameterGroupName(String dbClusterParameterGroupName); /** *

                * A list of VPC security groups that the DB cluster will belong to. *

                * * @param vpcSecurityGroupIds * A list of VPC security groups that the DB cluster will belong to. * @return Returns a reference to this object so that method calls can be chained together. */ Builder vpcSecurityGroupIds(Collection vpcSecurityGroupIds); /** *

                * A list of VPC security groups that the DB cluster will belong to. *

                * * @param vpcSecurityGroupIds * A list of VPC security groups that the DB cluster will belong to. * @return Returns a reference to this object so that method calls can be chained together. */ Builder vpcSecurityGroupIds(String... vpcSecurityGroupIds); /** *

                * The port number on which the DB cluster accepts connections. *

                *

                * Constraints: Value must be 1150-65535 *

                *

                * Default: The same port as the original DB cluster. *

                * * @param port * The port number on which the DB cluster accepts connections.

                *

                * Constraints: Value must be 1150-65535 *

                *

                * Default: The same port as the original DB cluster. * @return Returns a reference to this object so that method calls can be chained together. */ Builder port(Integer port); /** *

                * Not supported by Neptune. *

                * * @param masterUserPassword * Not supported by Neptune. * @return Returns a reference to this object so that method calls can be chained together. */ Builder masterUserPassword(String masterUserPassword); /** *

                * Not supported by Neptune. *

                * * @param optionGroupName * Not supported by Neptune. * @return Returns a reference to this object so that method calls can be chained together. */ Builder optionGroupName(String optionGroupName); /** *

                * The daily time range during which automated backups are created if automated backups are enabled, using the * BackupRetentionPeriod parameter. *

                *

                * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Region. *

                *

                * Constraints: *

                *
                  *
                • *

                  * Must be in the format hh24:mi-hh24:mi. *

                  *
                • *
                • *

                  * Must be in Universal Coordinated Time (UTC). *

                  *
                • *
                • *

                  * Must not conflict with the preferred maintenance window. *

                  *
                • *
                • *

                  * Must be at least 30 minutes. *

                  *
                • *
                * * @param preferredBackupWindow * The daily time range during which automated backups are created if automated backups are enabled, * using the BackupRetentionPeriod parameter.

                *

                * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon * Region. *

                *

                * Constraints: *

                *
                  *
                • *

                  * Must be in the format hh24:mi-hh24:mi. *

                  *
                • *
                • *

                  * Must be in Universal Coordinated Time (UTC). *

                  *
                • *
                • *

                  * Must not conflict with the preferred maintenance window. *

                  *
                • *
                • *

                  * Must be at least 30 minutes. *

                  *
                • * @return Returns a reference to this object so that method calls can be chained together. */ Builder preferredBackupWindow(String preferredBackupWindow); /** *

                  * The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC). *

                  *

                  * Format: ddd:hh24:mi-ddd:hh24:mi *

                  *

                  * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Region, * occurring on a random day of the week. *

                  *

                  * Valid Days: Mon, Tue, Wed, Thu, Fri, Sat, Sun. *

                  *

                  * Constraints: Minimum 30-minute window. *

                  * * @param preferredMaintenanceWindow * The weekly time range during which system maintenance can occur, in Universal Coordinated Time * (UTC).

                  *

                  * Format: ddd:hh24:mi-ddd:hh24:mi *

                  *

                  * The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon * Region, occurring on a random day of the week. *

                  *

                  * Valid Days: Mon, Tue, Wed, Thu, Fri, Sat, Sun. *

                  *

                  * Constraints: Minimum 30-minute window. * @return Returns a reference to this object so that method calls can be chained together. */ Builder preferredMaintenanceWindow(String preferredMaintenanceWindow); /** *

                  * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and * otherwise false. *

                  *

                  * Default: false *

                  * * @param enableIAMDatabaseAuthentication * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, * and otherwise false.

                  *

                  * Default: false * @return Returns a reference to this object so that method calls can be chained together. */ Builder enableIAMDatabaseAuthentication(Boolean enableIAMDatabaseAuthentication); /** *

                  * The configuration setting for the log types to be enabled for export to CloudWatch Logs for a specific DB * cluster. See Using * the CLI to publish Neptune audit logs to CloudWatch Logs. *

                  * * @param cloudwatchLogsExportConfiguration * The configuration setting for the log types to be enabled for export to CloudWatch Logs for a specific * DB cluster. See Using the CLI to publish Neptune audit logs to CloudWatch Logs. * @return Returns a reference to this object so that method calls can be chained together. */ Builder cloudwatchLogsExportConfiguration(CloudwatchLogsExportConfiguration cloudwatchLogsExportConfiguration); /** *

                  * The configuration setting for the log types to be enabled for export to CloudWatch Logs for a specific DB * cluster. See Using * the CLI to publish Neptune audit logs to CloudWatch Logs. *

                  * This is a convenience method that creates an instance of the * {@link CloudwatchLogsExportConfiguration.Builder} avoiding the need to create one manually via * {@link CloudwatchLogsExportConfiguration#builder()}. * *

                  * When the {@link Consumer} completes, {@link CloudwatchLogsExportConfiguration.Builder#build()} is called * immediately and its result is passed to * {@link #cloudwatchLogsExportConfiguration(CloudwatchLogsExportConfiguration)}. * * @param cloudwatchLogsExportConfiguration * a consumer that will call methods on {@link CloudwatchLogsExportConfiguration.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #cloudwatchLogsExportConfiguration(CloudwatchLogsExportConfiguration) */ default Builder cloudwatchLogsExportConfiguration( Consumer cloudwatchLogsExportConfiguration) { return cloudwatchLogsExportConfiguration(CloudwatchLogsExportConfiguration.builder() .applyMutation(cloudwatchLogsExportConfiguration).build()); } /** *

                  * The version number of the database engine to which you want to upgrade. Changing this parameter results in an * outage. The change is applied during the next maintenance window unless the ApplyImmediately * parameter is set to true. *

                  *

                  * For a list of valid engine versions, see Engine Releases for Amazon * Neptune, or call DescribeDBEngineVersions. *

                  * * @param engineVersion * The version number of the database engine to which you want to upgrade. Changing this parameter * results in an outage. The change is applied during the next maintenance window unless the * ApplyImmediately parameter is set to true.

                  *

                  * For a list of valid engine versions, see Engine Releases for * Amazon Neptune, or call DescribeDBEngineVersions. * @return Returns a reference to this object so that method calls can be chained together. */ Builder engineVersion(String engineVersion); /** *

                  * A value that indicates whether upgrades between different major versions are allowed. *

                  *

                  * Constraints: You must set the allow-major-version-upgrade flag when providing an EngineVersion * parameter that uses a different major version than the DB cluster's current version. *

                  * * @param allowMajorVersionUpgrade * A value that indicates whether upgrades between different major versions are allowed.

                  *

                  * Constraints: You must set the allow-major-version-upgrade flag when providing an * EngineVersion parameter that uses a different major version than the DB cluster's current * version. * @return Returns a reference to this object so that method calls can be chained together. */ Builder allowMajorVersionUpgrade(Boolean allowMajorVersionUpgrade); /** *

                  * The name of the DB parameter group to apply to all instances of the DB cluster. *

                  * *

                  * When you apply a parameter group using DBInstanceParameterGroupName, parameter changes aren't * applied during the next maintenance window but instead are applied immediately. *

                  *
                  *

                  * Default: The existing name setting *

                  *

                  * Constraints: *

                  *
                    *
                  • *

                    * The DB parameter group must be in the same DB parameter group family as the target DB cluster version. *

                    *
                  • *
                  • *

                    * The DBInstanceParameterGroupName parameter is only valid in combination with the * AllowMajorVersionUpgrade parameter. *

                    *
                  • *
                  * * @param dbInstanceParameterGroupName * The name of the DB parameter group to apply to all instances of the DB cluster.

                  *

                  * When you apply a parameter group using DBInstanceParameterGroupName, parameter changes * aren't applied during the next maintenance window but instead are applied immediately. *

                  *
                  *

                  * Default: The existing name setting *

                  *

                  * Constraints: *

                  *
                    *
                  • *

                    * The DB parameter group must be in the same DB parameter group family as the target DB cluster version. *

                    *
                  • *
                  • *

                    * The DBInstanceParameterGroupName parameter is only valid in combination with the * AllowMajorVersionUpgrade parameter. *

                    *
                  • * @return Returns a reference to this object so that method calls can be chained together. */ Builder dbInstanceParameterGroupName(String dbInstanceParameterGroupName); /** *

                    * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted * when deletion protection is enabled. By default, deletion protection is disabled. *

                    * * @param deletionProtection * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be * deleted when deletion protection is enabled. By default, deletion protection is disabled. * @return Returns a reference to this object so that method calls can be chained together. */ Builder deletionProtection(Boolean deletionProtection); /** *

                    * If set to true, tags are copied to any snapshot of the DB cluster that is created. *

                    * * @param copyTagsToSnapshot * If set to true, tags are copied to any snapshot of the DB cluster that is created. * @return Returns a reference to this object so that method calls can be chained together. */ Builder copyTagsToSnapshot(Boolean copyTagsToSnapshot); /** *

                    * Contains the scaling configuration of a Neptune Serverless DB cluster. *

                    *

                    * For more information, see Using Amazon * Neptune Serverless in the Amazon Neptune User Guide. *

                    * * @param serverlessV2ScalingConfiguration * Contains the scaling configuration of a Neptune Serverless DB cluster.

                    *

                    * For more information, see Using Amazon * Neptune Serverless in the Amazon Neptune User Guide. * @return Returns a reference to this object so that method calls can be chained together. */ Builder serverlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration); /** *

                    * Contains the scaling configuration of a Neptune Serverless DB cluster. *

                    *

                    * For more information, see Using Amazon * Neptune Serverless in the Amazon Neptune User Guide. *

                    * This is a convenience method that creates an instance of the {@link ServerlessV2ScalingConfiguration.Builder} * avoiding the need to create one manually via {@link ServerlessV2ScalingConfiguration#builder()}. * *

                    * When the {@link Consumer} completes, {@link ServerlessV2ScalingConfiguration.Builder#build()} is called * immediately and its result is passed to * {@link #serverlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration)}. * * @param serverlessV2ScalingConfiguration * a consumer that will call methods on {@link ServerlessV2ScalingConfiguration.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #serverlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration) */ default Builder serverlessV2ScalingConfiguration( Consumer serverlessV2ScalingConfiguration) { return serverlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration.builder() .applyMutation(serverlessV2ScalingConfiguration).build()); } /** *

                    * The storage type to associate with the DB cluster. *

                    *

                    * Valid Values: *

                    *
                      *
                    • *

                      * standard | iopt1 *

                      *
                    • *
                    *

                    * Default: *

                    *
                      *
                    • *

                      * standard *

                      *
                    • *
                    * * @param storageType * The storage type to associate with the DB cluster.

                    *

                    * Valid Values: *

                    *
                      *
                    • *

                      * standard | iopt1 *

                      *
                    • *
                    *

                    * Default: *

                    *
                      *
                    • *

                      * standard *

                      *
                    • * @return Returns a reference to this object so that method calls can be chained together. */ Builder storageType(String storageType); @Override Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration); @Override Builder overrideConfiguration(Consumer builderConsumer); } static final class BuilderImpl extends NeptuneRequest.BuilderImpl implements Builder { private String dbClusterIdentifier; private String newDBClusterIdentifier; private Boolean applyImmediately; private Integer backupRetentionPeriod; private String dbClusterParameterGroupName; private List vpcSecurityGroupIds = DefaultSdkAutoConstructList.getInstance(); private Integer port; private String masterUserPassword; private String optionGroupName; private String preferredBackupWindow; private String preferredMaintenanceWindow; private Boolean enableIAMDatabaseAuthentication; private CloudwatchLogsExportConfiguration cloudwatchLogsExportConfiguration; private String engineVersion; private Boolean allowMajorVersionUpgrade; private String dbInstanceParameterGroupName; private Boolean deletionProtection; private Boolean copyTagsToSnapshot; private ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration; private String storageType; private BuilderImpl() { } private BuilderImpl(ModifyDbClusterRequest model) { super(model); dbClusterIdentifier(model.dbClusterIdentifier); newDBClusterIdentifier(model.newDBClusterIdentifier); applyImmediately(model.applyImmediately); backupRetentionPeriod(model.backupRetentionPeriod); dbClusterParameterGroupName(model.dbClusterParameterGroupName); vpcSecurityGroupIds(model.vpcSecurityGroupIds); port(model.port); masterUserPassword(model.masterUserPassword); optionGroupName(model.optionGroupName); preferredBackupWindow(model.preferredBackupWindow); preferredMaintenanceWindow(model.preferredMaintenanceWindow); enableIAMDatabaseAuthentication(model.enableIAMDatabaseAuthentication); cloudwatchLogsExportConfiguration(model.cloudwatchLogsExportConfiguration); engineVersion(model.engineVersion); allowMajorVersionUpgrade(model.allowMajorVersionUpgrade); dbInstanceParameterGroupName(model.dbInstanceParameterGroupName); deletionProtection(model.deletionProtection); copyTagsToSnapshot(model.copyTagsToSnapshot); serverlessV2ScalingConfiguration(model.serverlessV2ScalingConfiguration); storageType(model.storageType); } public final String getDbClusterIdentifier() { return dbClusterIdentifier; } public final void setDbClusterIdentifier(String dbClusterIdentifier) { this.dbClusterIdentifier = dbClusterIdentifier; } @Override public final Builder dbClusterIdentifier(String dbClusterIdentifier) { this.dbClusterIdentifier = dbClusterIdentifier; return this; } public final String getNewDBClusterIdentifier() { return newDBClusterIdentifier; } public final void setNewDBClusterIdentifier(String newDBClusterIdentifier) { this.newDBClusterIdentifier = newDBClusterIdentifier; } @Override public final Builder newDBClusterIdentifier(String newDBClusterIdentifier) { this.newDBClusterIdentifier = newDBClusterIdentifier; return this; } public final Boolean getApplyImmediately() { return applyImmediately; } public final void setApplyImmediately(Boolean applyImmediately) { this.applyImmediately = applyImmediately; } @Override public final Builder applyImmediately(Boolean applyImmediately) { this.applyImmediately = applyImmediately; return this; } public final Integer getBackupRetentionPeriod() { return backupRetentionPeriod; } public final void setBackupRetentionPeriod(Integer backupRetentionPeriod) { this.backupRetentionPeriod = backupRetentionPeriod; } @Override public final Builder backupRetentionPeriod(Integer backupRetentionPeriod) { this.backupRetentionPeriod = backupRetentionPeriod; return this; } public final String getDbClusterParameterGroupName() { return dbClusterParameterGroupName; } public final void setDbClusterParameterGroupName(String dbClusterParameterGroupName) { this.dbClusterParameterGroupName = dbClusterParameterGroupName; } @Override public final Builder dbClusterParameterGroupName(String dbClusterParameterGroupName) { this.dbClusterParameterGroupName = dbClusterParameterGroupName; return this; } public final Collection getVpcSecurityGroupIds() { if (vpcSecurityGroupIds instanceof SdkAutoConstructList) { return null; } return vpcSecurityGroupIds; } public final void setVpcSecurityGroupIds(Collection vpcSecurityGroupIds) { this.vpcSecurityGroupIds = VpcSecurityGroupIdListCopier.copy(vpcSecurityGroupIds); } @Override public final Builder vpcSecurityGroupIds(Collection vpcSecurityGroupIds) { this.vpcSecurityGroupIds = VpcSecurityGroupIdListCopier.copy(vpcSecurityGroupIds); return this; } @Override @SafeVarargs public final Builder vpcSecurityGroupIds(String... vpcSecurityGroupIds) { vpcSecurityGroupIds(Arrays.asList(vpcSecurityGroupIds)); return this; } public final Integer getPort() { return port; } public final void setPort(Integer port) { this.port = port; } @Override public final Builder port(Integer port) { this.port = port; return this; } public final String getMasterUserPassword() { return masterUserPassword; } public final void setMasterUserPassword(String masterUserPassword) { this.masterUserPassword = masterUserPassword; } @Override public final Builder masterUserPassword(String masterUserPassword) { this.masterUserPassword = masterUserPassword; return this; } public final String getOptionGroupName() { return optionGroupName; } public final void setOptionGroupName(String optionGroupName) { this.optionGroupName = optionGroupName; } @Override public final Builder optionGroupName(String optionGroupName) { this.optionGroupName = optionGroupName; return this; } public final String getPreferredBackupWindow() { return preferredBackupWindow; } public final void setPreferredBackupWindow(String preferredBackupWindow) { this.preferredBackupWindow = preferredBackupWindow; } @Override public final Builder preferredBackupWindow(String preferredBackupWindow) { this.preferredBackupWindow = preferredBackupWindow; return this; } public final String getPreferredMaintenanceWindow() { return preferredMaintenanceWindow; } public final void setPreferredMaintenanceWindow(String preferredMaintenanceWindow) { this.preferredMaintenanceWindow = preferredMaintenanceWindow; } @Override public final Builder preferredMaintenanceWindow(String preferredMaintenanceWindow) { this.preferredMaintenanceWindow = preferredMaintenanceWindow; return this; } public final Boolean getEnableIAMDatabaseAuthentication() { return enableIAMDatabaseAuthentication; } public final void setEnableIAMDatabaseAuthentication(Boolean enableIAMDatabaseAuthentication) { this.enableIAMDatabaseAuthentication = enableIAMDatabaseAuthentication; } @Override public final Builder enableIAMDatabaseAuthentication(Boolean enableIAMDatabaseAuthentication) { this.enableIAMDatabaseAuthentication = enableIAMDatabaseAuthentication; return this; } public final CloudwatchLogsExportConfiguration.Builder getCloudwatchLogsExportConfiguration() { return cloudwatchLogsExportConfiguration != null ? cloudwatchLogsExportConfiguration.toBuilder() : null; } public final void setCloudwatchLogsExportConfiguration( CloudwatchLogsExportConfiguration.BuilderImpl cloudwatchLogsExportConfiguration) { this.cloudwatchLogsExportConfiguration = cloudwatchLogsExportConfiguration != null ? cloudwatchLogsExportConfiguration .build() : null; } @Override public final Builder cloudwatchLogsExportConfiguration(CloudwatchLogsExportConfiguration cloudwatchLogsExportConfiguration) { this.cloudwatchLogsExportConfiguration = cloudwatchLogsExportConfiguration; return this; } public final String getEngineVersion() { return engineVersion; } public final void setEngineVersion(String engineVersion) { this.engineVersion = engineVersion; } @Override public final Builder engineVersion(String engineVersion) { this.engineVersion = engineVersion; return this; } public final Boolean getAllowMajorVersionUpgrade() { return allowMajorVersionUpgrade; } public final void setAllowMajorVersionUpgrade(Boolean allowMajorVersionUpgrade) { this.allowMajorVersionUpgrade = allowMajorVersionUpgrade; } @Override public final Builder allowMajorVersionUpgrade(Boolean allowMajorVersionUpgrade) { this.allowMajorVersionUpgrade = allowMajorVersionUpgrade; return this; } public final String getDbInstanceParameterGroupName() { return dbInstanceParameterGroupName; } public final void setDbInstanceParameterGroupName(String dbInstanceParameterGroupName) { this.dbInstanceParameterGroupName = dbInstanceParameterGroupName; } @Override public final Builder dbInstanceParameterGroupName(String dbInstanceParameterGroupName) { this.dbInstanceParameterGroupName = dbInstanceParameterGroupName; return this; } public final Boolean getDeletionProtection() { return deletionProtection; } public final void setDeletionProtection(Boolean deletionProtection) { this.deletionProtection = deletionProtection; } @Override public final Builder deletionProtection(Boolean deletionProtection) { this.deletionProtection = deletionProtection; return this; } public final Boolean getCopyTagsToSnapshot() { return copyTagsToSnapshot; } public final void setCopyTagsToSnapshot(Boolean copyTagsToSnapshot) { this.copyTagsToSnapshot = copyTagsToSnapshot; } @Override public final Builder copyTagsToSnapshot(Boolean copyTagsToSnapshot) { this.copyTagsToSnapshot = copyTagsToSnapshot; return this; } public final ServerlessV2ScalingConfiguration.Builder getServerlessV2ScalingConfiguration() { return serverlessV2ScalingConfiguration != null ? serverlessV2ScalingConfiguration.toBuilder() : null; } public final void setServerlessV2ScalingConfiguration( ServerlessV2ScalingConfiguration.BuilderImpl serverlessV2ScalingConfiguration) { this.serverlessV2ScalingConfiguration = serverlessV2ScalingConfiguration != null ? serverlessV2ScalingConfiguration .build() : null; } @Override public final Builder serverlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration) { this.serverlessV2ScalingConfiguration = serverlessV2ScalingConfiguration; return this; } public final String getStorageType() { return storageType; } public final void setStorageType(String storageType) { this.storageType = storageType; } @Override public final Builder storageType(String storageType) { this.storageType = storageType; return this; } @Override public Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) { super.overrideConfiguration(overrideConfiguration); return this; } @Override public Builder overrideConfiguration(Consumer builderConsumer) { super.overrideConfiguration(builderConsumer); return this; } @Override public ModifyDbClusterRequest build() { return new ModifyDbClusterRequest(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy