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

software.amazon.awssdk.services.databasemigration.DefaultDatabaseMigrationAsyncClient Maven / Gradle / Ivy

Go to download

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

The newest version!
/*
 * Copyright 2013-2018 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.databasemigration;

import java.util.concurrent.CompletableFuture;
import java.util.function.Consumer;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.annotations.SdkInternalApi;
import software.amazon.awssdk.awscore.AwsRequestOverrideConfiguration;
import software.amazon.awssdk.awscore.client.handler.AwsAsyncClientHandler;
import software.amazon.awssdk.awscore.exception.AwsServiceException;
import software.amazon.awssdk.awscore.internal.protocol.json.AwsJsonProtocol;
import software.amazon.awssdk.awscore.protocol.json.AwsJsonProtocolFactory;
import software.amazon.awssdk.awscore.protocol.json.AwsJsonProtocolMetadata;
import software.amazon.awssdk.core.ApiName;
import software.amazon.awssdk.core.client.handler.AsyncClientHandler;
import software.amazon.awssdk.core.client.handler.ClientExecutionParams;
import software.amazon.awssdk.core.http.HttpResponseHandler;
import software.amazon.awssdk.core.internal.client.config.SdkClientConfiguration;
import software.amazon.awssdk.core.protocol.json.JsonClientMetadata;
import software.amazon.awssdk.core.protocol.json.JsonErrorResponseMetadata;
import software.amazon.awssdk.core.protocol.json.JsonErrorShapeMetadata;
import software.amazon.awssdk.core.protocol.json.JsonOperationMetadata;
import software.amazon.awssdk.core.util.VersionInfo;
import software.amazon.awssdk.services.databasemigration.model.AccessDeniedException;
import software.amazon.awssdk.services.databasemigration.model.AddTagsToResourceRequest;
import software.amazon.awssdk.services.databasemigration.model.AddTagsToResourceResponse;
import software.amazon.awssdk.services.databasemigration.model.CreateEndpointRequest;
import software.amazon.awssdk.services.databasemigration.model.CreateEndpointResponse;
import software.amazon.awssdk.services.databasemigration.model.CreateEventSubscriptionRequest;
import software.amazon.awssdk.services.databasemigration.model.CreateEventSubscriptionResponse;
import software.amazon.awssdk.services.databasemigration.model.CreateReplicationInstanceRequest;
import software.amazon.awssdk.services.databasemigration.model.CreateReplicationInstanceResponse;
import software.amazon.awssdk.services.databasemigration.model.CreateReplicationSubnetGroupRequest;
import software.amazon.awssdk.services.databasemigration.model.CreateReplicationSubnetGroupResponse;
import software.amazon.awssdk.services.databasemigration.model.CreateReplicationTaskRequest;
import software.amazon.awssdk.services.databasemigration.model.CreateReplicationTaskResponse;
import software.amazon.awssdk.services.databasemigration.model.DatabaseMigrationRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteCertificateRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteCertificateResponse;
import software.amazon.awssdk.services.databasemigration.model.DeleteEndpointRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteEndpointResponse;
import software.amazon.awssdk.services.databasemigration.model.DeleteEventSubscriptionRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteEventSubscriptionResponse;
import software.amazon.awssdk.services.databasemigration.model.DeleteReplicationInstanceRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteReplicationInstanceResponse;
import software.amazon.awssdk.services.databasemigration.model.DeleteReplicationSubnetGroupRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteReplicationSubnetGroupResponse;
import software.amazon.awssdk.services.databasemigration.model.DeleteReplicationTaskRequest;
import software.amazon.awssdk.services.databasemigration.model.DeleteReplicationTaskResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeAccountAttributesRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeAccountAttributesResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeCertificatesRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeCertificatesResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeConnectionsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeConnectionsResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeEndpointTypesRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeEndpointTypesResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeEndpointsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeEndpointsResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeEventCategoriesRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeEventCategoriesResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeEventSubscriptionsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeEventSubscriptionsResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeEventsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeEventsResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeOrderableReplicationInstancesRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeOrderableReplicationInstancesResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeRefreshSchemasStatusRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeRefreshSchemasStatusResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationInstancesRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationInstancesResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationSubnetGroupsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationSubnetGroupsResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTaskAssessmentResultsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTaskAssessmentResultsResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTasksRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTasksResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeSchemasRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeSchemasResponse;
import software.amazon.awssdk.services.databasemigration.model.DescribeTableStatisticsRequest;
import software.amazon.awssdk.services.databasemigration.model.DescribeTableStatisticsResponse;
import software.amazon.awssdk.services.databasemigration.model.ImportCertificateRequest;
import software.amazon.awssdk.services.databasemigration.model.ImportCertificateResponse;
import software.amazon.awssdk.services.databasemigration.model.InsufficientResourceCapacityException;
import software.amazon.awssdk.services.databasemigration.model.InvalidCertificateException;
import software.amazon.awssdk.services.databasemigration.model.InvalidResourceStateException;
import software.amazon.awssdk.services.databasemigration.model.InvalidSubnetException;
import software.amazon.awssdk.services.databasemigration.model.KmsKeyNotAccessibleException;
import software.amazon.awssdk.services.databasemigration.model.ListTagsForResourceRequest;
import software.amazon.awssdk.services.databasemigration.model.ListTagsForResourceResponse;
import software.amazon.awssdk.services.databasemigration.model.ModifyEndpointRequest;
import software.amazon.awssdk.services.databasemigration.model.ModifyEndpointResponse;
import software.amazon.awssdk.services.databasemigration.model.ModifyEventSubscriptionRequest;
import software.amazon.awssdk.services.databasemigration.model.ModifyEventSubscriptionResponse;
import software.amazon.awssdk.services.databasemigration.model.ModifyReplicationInstanceRequest;
import software.amazon.awssdk.services.databasemigration.model.ModifyReplicationInstanceResponse;
import software.amazon.awssdk.services.databasemigration.model.ModifyReplicationSubnetGroupRequest;
import software.amazon.awssdk.services.databasemigration.model.ModifyReplicationSubnetGroupResponse;
import software.amazon.awssdk.services.databasemigration.model.ModifyReplicationTaskRequest;
import software.amazon.awssdk.services.databasemigration.model.ModifyReplicationTaskResponse;
import software.amazon.awssdk.services.databasemigration.model.RefreshSchemasRequest;
import software.amazon.awssdk.services.databasemigration.model.RefreshSchemasResponse;
import software.amazon.awssdk.services.databasemigration.model.ReloadTablesRequest;
import software.amazon.awssdk.services.databasemigration.model.ReloadTablesResponse;
import software.amazon.awssdk.services.databasemigration.model.RemoveTagsFromResourceRequest;
import software.amazon.awssdk.services.databasemigration.model.RemoveTagsFromResourceResponse;
import software.amazon.awssdk.services.databasemigration.model.ReplicationSubnetGroupDoesNotCoverEnoughAZsException;
import software.amazon.awssdk.services.databasemigration.model.ResourceAlreadyExistsException;
import software.amazon.awssdk.services.databasemigration.model.ResourceNotFoundException;
import software.amazon.awssdk.services.databasemigration.model.ResourceQuotaExceededException;
import software.amazon.awssdk.services.databasemigration.model.SnsInvalidTopicException;
import software.amazon.awssdk.services.databasemigration.model.SnsNoAuthorizationException;
import software.amazon.awssdk.services.databasemigration.model.StartReplicationTaskAssessmentRequest;
import software.amazon.awssdk.services.databasemigration.model.StartReplicationTaskAssessmentResponse;
import software.amazon.awssdk.services.databasemigration.model.StartReplicationTaskRequest;
import software.amazon.awssdk.services.databasemigration.model.StartReplicationTaskResponse;
import software.amazon.awssdk.services.databasemigration.model.StopReplicationTaskRequest;
import software.amazon.awssdk.services.databasemigration.model.StopReplicationTaskResponse;
import software.amazon.awssdk.services.databasemigration.model.StorageQuotaExceededException;
import software.amazon.awssdk.services.databasemigration.model.SubnetAlreadyInUseException;
import software.amazon.awssdk.services.databasemigration.model.TestConnectionRequest;
import software.amazon.awssdk.services.databasemigration.model.TestConnectionResponse;
import software.amazon.awssdk.services.databasemigration.model.UpgradeDependencyFailureException;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeCertificatesPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeConnectionsPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeEndpointTypesPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeEndpointsPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeEventSubscriptionsPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeEventsPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeOrderableReplicationInstancesPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationInstancesPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationSubnetGroupsPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationTasksPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeSchemasPublisher;
import software.amazon.awssdk.services.databasemigration.paginators.DescribeTableStatisticsPublisher;
import software.amazon.awssdk.services.databasemigration.transform.AddTagsToResourceRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.AddTagsToResourceResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateEndpointRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateEndpointResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateEventSubscriptionRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateEventSubscriptionResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateReplicationInstanceRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateReplicationInstanceResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateReplicationSubnetGroupRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateReplicationSubnetGroupResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateReplicationTaskRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.CreateReplicationTaskResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteCertificateRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteCertificateResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteEndpointRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteEndpointResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteEventSubscriptionRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteEventSubscriptionResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteReplicationInstanceRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteReplicationInstanceResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteReplicationSubnetGroupRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteReplicationSubnetGroupResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteReplicationTaskRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DeleteReplicationTaskResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeAccountAttributesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeAccountAttributesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeCertificatesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeCertificatesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeConnectionsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeConnectionsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEndpointTypesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEndpointTypesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEndpointsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEndpointsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEventCategoriesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEventCategoriesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEventSubscriptionsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEventSubscriptionsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEventsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeEventsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeOrderableReplicationInstancesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeOrderableReplicationInstancesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeRefreshSchemasStatusRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeRefreshSchemasStatusResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationInstancesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationInstancesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationSubnetGroupsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationSubnetGroupsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationTaskAssessmentResultsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationTaskAssessmentResultsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationTasksRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeReplicationTasksResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeSchemasRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeSchemasResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeTableStatisticsRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.DescribeTableStatisticsResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ImportCertificateRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ImportCertificateResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ListTagsForResourceRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ListTagsForResourceResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyEndpointRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyEndpointResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyEventSubscriptionRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyEventSubscriptionResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyReplicationInstanceRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyReplicationInstanceResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyReplicationSubnetGroupRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyReplicationSubnetGroupResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyReplicationTaskRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ModifyReplicationTaskResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.RefreshSchemasRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.RefreshSchemasResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ReloadTablesRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.ReloadTablesResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.RemoveTagsFromResourceRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.RemoveTagsFromResourceResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.StartReplicationTaskAssessmentRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.StartReplicationTaskAssessmentResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.StartReplicationTaskRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.StartReplicationTaskResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.StopReplicationTaskRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.StopReplicationTaskResponseUnmarshaller;
import software.amazon.awssdk.services.databasemigration.transform.TestConnectionRequestMarshaller;
import software.amazon.awssdk.services.databasemigration.transform.TestConnectionResponseUnmarshaller;
import software.amazon.awssdk.utils.CompletableFutureUtils;

/**
 * Internal implementation of {@link DatabaseMigrationAsyncClient}.
 *
 * @see DatabaseMigrationAsyncClient#builder()
 */
@Generated("software.amazon.awssdk:codegen")
@SdkInternalApi
final class DefaultDatabaseMigrationAsyncClient implements DatabaseMigrationAsyncClient {
    private final AsyncClientHandler clientHandler;

    private final AwsJsonProtocolFactory protocolFactory;

    protected DefaultDatabaseMigrationAsyncClient(SdkClientConfiguration clientConfiguration) {
        this.clientHandler = new AwsAsyncClientHandler(clientConfiguration);
        this.protocolFactory = init();
    }

    @Override
    public final String serviceName() {
        return SERVICE_NAME;
    }

    /**
     * 

* Adds metadata tags to a DMS resource, including replication instance, endpoint, security group, and migration * task. These tags can also be used with cost allocation reporting to track cost associated with DMS resources, or * used in a Condition statement in an IAM policy for DMS. *

* * @param addTagsToResourceRequest * @return A Java Future containing the result of the AddTagsToResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.AddTagsToResource * @see AWS API * Documentation */ @Override public CompletableFuture addTagsToResource(AddTagsToResourceRequest addTagsToResourceRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new AddTagsToResourceResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new AddTagsToResourceRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(addTagsToResourceRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Creates an endpoint using the provided settings. *

* * @param createEndpointRequest * @return A Java Future containing the result of the CreateEndpoint operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • AccessDeniedException AWS DMS was denied access to the endpoint.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.CreateEndpoint * @see AWS API * Documentation */ @Override public CompletableFuture createEndpoint(CreateEndpointRequest createEndpointRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new CreateEndpointResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new CreateEndpointRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(createEndpointRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Creates an AWS DMS event notification subscription. *

*

* You can specify the type of source (SourceType) you want to be notified of, provide a list of AWS * DMS source IDs (SourceIds) that triggers the events, and provide a list of event categories ( * EventCategories) for events you want to be notified of. If you specify both the * SourceType and SourceIds, such as SourceType = replication-instance and * SourceIdentifier = my-replinstance, you will be notified of all the replication instance events for * the specified source. If you specify a SourceType but don't specify a SourceIdentifier, * you receive notice of the events for that source type for all your AWS DMS sources. If you don't specify either * SourceType nor SourceIdentifier, you will be notified of events generated from all AWS * DMS sources belonging to your customer account. *

*

* For more information about AWS DMS events, see Working with Events and Notifications * in the AWS Database MIgration Service User Guide. *

* * @param createEventSubscriptionRequest * @return A Java Future containing the result of the CreateEventSubscription operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • SnsInvalidTopicException The SNS topic is invalid.
  • *
  • SnsNoAuthorizationException You are not authorized for the SNS subscription.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.CreateEventSubscription * @see AWS * API Documentation */ @Override public CompletableFuture createEventSubscription( CreateEventSubscriptionRequest createEventSubscriptionRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new CreateEventSubscriptionResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new CreateEventSubscriptionRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(createEventSubscriptionRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Creates the replication instance using the specified parameters. *

* * @param createReplicationInstanceRequest * @return A Java Future containing the result of the CreateReplicationInstance operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • AccessDeniedException AWS DMS was denied access to the endpoint.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • InsufficientResourceCapacityException There are not enough resources allocated to the database * migration.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • StorageQuotaExceededException The storage quota has been exceeded.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • ReplicationSubnetGroupDoesNotCoverEnoughAZsException The replication subnet group does not cover * enough Availability Zones (AZs). Edit the replication subnet group and add more AZs.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • InvalidSubnetException The subnet provided is invalid.
  • *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.CreateReplicationInstance * @see AWS * API Documentation */ @Override public CompletableFuture createReplicationInstance( CreateReplicationInstanceRequest createReplicationInstanceRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new CreateReplicationInstanceResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new CreateReplicationInstanceRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(createReplicationInstanceRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Creates a replication subnet group given a list of the subnet IDs in a VPC. *

* * @param createReplicationSubnetGroupRequest * @return A Java Future containing the result of the CreateReplicationSubnetGroup operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • AccessDeniedException AWS DMS was denied access to the endpoint.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • ReplicationSubnetGroupDoesNotCoverEnoughAZsException The replication subnet group does not cover * enough Availability Zones (AZs). Edit the replication subnet group and add more AZs.
  • *
  • InvalidSubnetException The subnet provided is invalid.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.CreateReplicationSubnetGroup * @see AWS API Documentation */ @Override public CompletableFuture createReplicationSubnetGroup( CreateReplicationSubnetGroupRequest createReplicationSubnetGroupRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new CreateReplicationSubnetGroupResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new CreateReplicationSubnetGroupRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(createReplicationSubnetGroupRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Creates a replication task using the specified parameters. *

* * @param createReplicationTaskRequest * @return A Java Future containing the result of the CreateReplicationTask operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • AccessDeniedException AWS DMS was denied access to the endpoint.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.CreateReplicationTask * @see AWS API * Documentation */ @Override public CompletableFuture createReplicationTask( CreateReplicationTaskRequest createReplicationTaskRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new CreateReplicationTaskResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new CreateReplicationTaskRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(createReplicationTaskRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Deletes the specified certificate. *

* * @param deleteCertificateRequest * @return A Java Future containing the result of the DeleteCertificate operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DeleteCertificate * @see AWS API * Documentation */ @Override public CompletableFuture deleteCertificate(DeleteCertificateRequest deleteCertificateRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DeleteCertificateResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DeleteCertificateRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(deleteCertificateRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Deletes the specified endpoint. *

* *

* All tasks associated with the endpoint must be deleted before you can delete the endpoint. *

*
*

* * @param deleteEndpointRequest * @return A Java Future containing the result of the DeleteEndpoint operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *

    *
  • ResourceNotFoundException The resource could not be found.
  • InvalidResourceStateException The * resource is in a state that prevents it from being used for database migration.
  • SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios.
  • SdkClientException If any client side error occurs such as an IO related * failure, failure to get credentials, etc.
  • DatabaseMigrationException Base class for all service * exceptions. Unknown exceptions will be thrown as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DeleteEndpoint * @see AWS API * Documentation */ @Override public CompletableFuture deleteEndpoint(DeleteEndpointRequest deleteEndpointRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DeleteEndpointResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DeleteEndpointRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(deleteEndpointRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Deletes an AWS DMS event subscription. *

* * @param deleteEventSubscriptionRequest * @return A Java Future containing the result of the DeleteEventSubscription operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DeleteEventSubscription * @see AWS * API Documentation */ @Override public CompletableFuture deleteEventSubscription( DeleteEventSubscriptionRequest deleteEventSubscriptionRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DeleteEventSubscriptionResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DeleteEventSubscriptionRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(deleteEventSubscriptionRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Deletes the specified replication instance. *

* *

* You must delete any migration tasks that are associated with the replication instance before you can delete it. *

*
*

* * @param deleteReplicationInstanceRequest * @return A Java Future containing the result of the DeleteReplicationInstance operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *

    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • ResourceNotFoundException The resource could not be found.
  • * SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can * be used for catch all scenarios.
  • SdkClientException If any client side error occurs such as an * IO related failure, failure to get credentials, etc.
  • DatabaseMigrationException Base class for * all service exceptions. Unknown exceptions will be thrown as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DeleteReplicationInstance * @see AWS * API Documentation */ @Override public CompletableFuture deleteReplicationInstance( DeleteReplicationInstanceRequest deleteReplicationInstanceRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DeleteReplicationInstanceResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DeleteReplicationInstanceRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(deleteReplicationInstanceRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Deletes a subnet group. *

* * @param deleteReplicationSubnetGroupRequest * @return A Java Future containing the result of the DeleteReplicationSubnetGroup operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DeleteReplicationSubnetGroup * @see AWS API Documentation */ @Override public CompletableFuture deleteReplicationSubnetGroup( DeleteReplicationSubnetGroupRequest deleteReplicationSubnetGroupRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DeleteReplicationSubnetGroupResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DeleteReplicationSubnetGroupRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(deleteReplicationSubnetGroupRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Deletes the specified replication task. *

* * @param deleteReplicationTaskRequest * @return A Java Future containing the result of the DeleteReplicationTask operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DeleteReplicationTask * @see AWS API * Documentation */ @Override public CompletableFuture deleteReplicationTask( DeleteReplicationTaskRequest deleteReplicationTaskRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DeleteReplicationTaskResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DeleteReplicationTaskRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(deleteReplicationTaskRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Lists all of the AWS DMS attributes for a customer account. The attributes include AWS DMS quotas for the * account, such as the number of replication instances allowed. The description for a quota includes the quota * name, current usage toward that quota, and the quota's maximum value. *

*

* This command does not take any parameters. *

* * @param describeAccountAttributesRequest * @return A Java Future containing the result of the DescribeAccountAttributes operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeAccountAttributes * @see AWS * API Documentation */ @Override public CompletableFuture describeAccountAttributes( DescribeAccountAttributesRequest describeAccountAttributesRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeAccountAttributesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeAccountAttributesRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeAccountAttributesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Provides a description of the certificate. *

* * @param describeCertificatesRequest * @return A Java Future containing the result of the DescribeCertificates operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeCertificates * @see AWS API * Documentation */ @Override public CompletableFuture describeCertificates( DescribeCertificatesRequest describeCertificatesRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeCertificatesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DescribeCertificatesRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeCertificatesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Provides a description of the certificate. *

*
*

* This is a variant of * {@link #describeCertificates(software.amazon.awssdk.services.databasemigration.model.DescribeCertificatesRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeCertificatesPublisher publisher = client.describeCertificatesPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeCertificatesPublisher publisher = client.describeCertificatesPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeCertificatesResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeCertificates(software.amazon.awssdk.services.databasemigration.model.DescribeCertificatesRequest)} * operation. *

* * @param describeCertificatesRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeCertificates * @see AWS API * Documentation */ public DescribeCertificatesPublisher describeCertificatesPaginator(DescribeCertificatesRequest describeCertificatesRequest) { return new DescribeCertificatesPublisher(this, applyPaginatorUserAgent(describeCertificatesRequest)); } /** *

* Describes the status of the connections that have been made between the replication instance and an endpoint. * Connections are created when you test an endpoint. *

* * @param describeConnectionsRequest * @return A Java Future containing the result of the DescribeConnections operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeConnections * @see AWS API * Documentation */ @Override public CompletableFuture describeConnections( DescribeConnectionsRequest describeConnectionsRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeConnectionsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DescribeConnectionsRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeConnectionsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Describes the status of the connections that have been made between the replication instance and an endpoint. * Connections are created when you test an endpoint. *

*
*

* This is a variant of * {@link #describeConnections(software.amazon.awssdk.services.databasemigration.model.DescribeConnectionsRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeConnectionsPublisher publisher = client.describeConnectionsPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeConnectionsPublisher publisher = client.describeConnectionsPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeConnectionsResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeConnections(software.amazon.awssdk.services.databasemigration.model.DescribeConnectionsRequest)} * operation. *

* * @param describeConnectionsRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeConnections * @see AWS API * Documentation */ public DescribeConnectionsPublisher describeConnectionsPaginator(DescribeConnectionsRequest describeConnectionsRequest) { return new DescribeConnectionsPublisher(this, applyPaginatorUserAgent(describeConnectionsRequest)); } /** *

* Returns information about the type of endpoints available. *

* * @param describeEndpointTypesRequest * @return A Java Future containing the result of the DescribeEndpointTypes operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEndpointTypes * @see AWS API * Documentation */ @Override public CompletableFuture describeEndpointTypes( DescribeEndpointTypesRequest describeEndpointTypesRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeEndpointTypesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DescribeEndpointTypesRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeEndpointTypesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about the type of endpoints available. *

*
*

* This is a variant of * {@link #describeEndpointTypes(software.amazon.awssdk.services.databasemigration.model.DescribeEndpointTypesRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEndpointTypesPublisher publisher = client.describeEndpointTypesPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEndpointTypesPublisher publisher = client.describeEndpointTypesPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeEndpointTypesResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeEndpointTypes(software.amazon.awssdk.services.databasemigration.model.DescribeEndpointTypesRequest)} * operation. *

* * @param describeEndpointTypesRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEndpointTypes * @see AWS API * Documentation */ public DescribeEndpointTypesPublisher describeEndpointTypesPaginator(DescribeEndpointTypesRequest describeEndpointTypesRequest) { return new DescribeEndpointTypesPublisher(this, applyPaginatorUserAgent(describeEndpointTypesRequest)); } /** *

* Returns information about the endpoints for your account in the current region. *

* * @param describeEndpointsRequest * @return A Java Future containing the result of the DescribeEndpoints operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEndpoints * @see AWS API * Documentation */ @Override public CompletableFuture describeEndpoints(DescribeEndpointsRequest describeEndpointsRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeEndpointsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DescribeEndpointsRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(describeEndpointsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about the endpoints for your account in the current region. *

*
*

* This is a variant of * {@link #describeEndpoints(software.amazon.awssdk.services.databasemigration.model.DescribeEndpointsRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEndpointsPublisher publisher = client.describeEndpointsPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEndpointsPublisher publisher = client.describeEndpointsPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeEndpointsResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeEndpoints(software.amazon.awssdk.services.databasemigration.model.DescribeEndpointsRequest)} * operation. *

* * @param describeEndpointsRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEndpoints * @see AWS API * Documentation */ public DescribeEndpointsPublisher describeEndpointsPaginator(DescribeEndpointsRequest describeEndpointsRequest) { return new DescribeEndpointsPublisher(this, applyPaginatorUserAgent(describeEndpointsRequest)); } /** *

* Lists categories for all event source types, or, if specified, for a specified source type. You can see a list of * the event categories and source types in Working with Events and Notifications * in the AWS Database Migration Service User Guide. *

* * @param describeEventCategoriesRequest * @return A Java Future containing the result of the DescribeEventCategories operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEventCategories * @see AWS * API Documentation */ @Override public CompletableFuture describeEventCategories( DescribeEventCategoriesRequest describeEventCategoriesRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeEventCategoriesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeEventCategoriesRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeEventCategoriesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Lists all the event subscriptions for a customer account. The description of a subscription includes * SubscriptionName, SNSTopicARN, CustomerID, SourceType, * SourceID, CreationTime, and Status. *

*

* If you specify SubscriptionName, this action lists the description for that subscription. *

* * @param describeEventSubscriptionsRequest * @return A Java Future containing the result of the DescribeEventSubscriptions operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEventSubscriptions * @see AWS * API Documentation */ @Override public CompletableFuture describeEventSubscriptions( DescribeEventSubscriptionsRequest describeEventSubscriptionsRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeEventSubscriptionsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeEventSubscriptionsRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeEventSubscriptionsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Lists all the event subscriptions for a customer account. The description of a subscription includes * SubscriptionName, SNSTopicARN, CustomerID, SourceType, * SourceID, CreationTime, and Status. *

*

* If you specify SubscriptionName, this action lists the description for that subscription. *

*
*

* This is a variant of * {@link #describeEventSubscriptions(software.amazon.awssdk.services.databasemigration.model.DescribeEventSubscriptionsRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEventSubscriptionsPublisher publisher = client.describeEventSubscriptionsPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEventSubscriptionsPublisher publisher = client.describeEventSubscriptionsPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeEventSubscriptionsResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeEventSubscriptions(software.amazon.awssdk.services.databasemigration.model.DescribeEventSubscriptionsRequest)} * operation. *

* * @param describeEventSubscriptionsRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEventSubscriptions * @see AWS * API Documentation */ public DescribeEventSubscriptionsPublisher describeEventSubscriptionsPaginator( DescribeEventSubscriptionsRequest describeEventSubscriptionsRequest) { return new DescribeEventSubscriptionsPublisher(this, applyPaginatorUserAgent(describeEventSubscriptionsRequest)); } /** *

* Lists events for a given source identifier and source type. You can also specify a start and end time. For more * information on AWS DMS events, see * Working with Events and Notifications . *

* * @param describeEventsRequest * @return A Java Future containing the result of the DescribeEvents operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEvents * @see AWS API * Documentation */ @Override public CompletableFuture describeEvents(DescribeEventsRequest describeEventsRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeEventsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DescribeEventsRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(describeEventsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Lists events for a given source identifier and source type. You can also specify a start and end time. For more * information on AWS DMS events, see * Working with Events and Notifications . *

*
*

* This is a variant of * {@link #describeEvents(software.amazon.awssdk.services.databasemigration.model.DescribeEventsRequest)} operation. * The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will * internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEventsPublisher publisher = client.describeEventsPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeEventsPublisher publisher = client.describeEventsPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeEventsResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeEvents(software.amazon.awssdk.services.databasemigration.model.DescribeEventsRequest)} * operation. *

* * @param describeEventsRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeEvents * @see AWS API * Documentation */ public DescribeEventsPublisher describeEventsPaginator(DescribeEventsRequest describeEventsRequest) { return new DescribeEventsPublisher(this, applyPaginatorUserAgent(describeEventsRequest)); } /** *

* Returns information about the replication instance types that can be created in the specified region. *

* * @param describeOrderableReplicationInstancesRequest * @return A Java Future containing the result of the DescribeOrderableReplicationInstances operation returned by * the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeOrderableReplicationInstances * @see AWS API Documentation */ @Override public CompletableFuture describeOrderableReplicationInstances( DescribeOrderableReplicationInstancesRequest describeOrderableReplicationInstancesRequest) { try { HttpResponseHandler responseHandler = protocolFactory .createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeOrderableReplicationInstancesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeOrderableReplicationInstancesRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeOrderableReplicationInstancesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about the replication instance types that can be created in the specified region. *

*
*

* This is a variant of * {@link #describeOrderableReplicationInstances(software.amazon.awssdk.services.databasemigration.model.DescribeOrderableReplicationInstancesRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeOrderableReplicationInstancesPublisher publisher = client.describeOrderableReplicationInstancesPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeOrderableReplicationInstancesPublisher publisher = client.describeOrderableReplicationInstancesPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeOrderableReplicationInstancesResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeOrderableReplicationInstances(software.amazon.awssdk.services.databasemigration.model.DescribeOrderableReplicationInstancesRequest)} * operation. *

* * @param describeOrderableReplicationInstancesRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeOrderableReplicationInstances * @see AWS API Documentation */ public DescribeOrderableReplicationInstancesPublisher describeOrderableReplicationInstancesPaginator( DescribeOrderableReplicationInstancesRequest describeOrderableReplicationInstancesRequest) { return new DescribeOrderableReplicationInstancesPublisher(this, applyPaginatorUserAgent(describeOrderableReplicationInstancesRequest)); } /** *

* Returns the status of the RefreshSchemas operation. *

* * @param describeRefreshSchemasStatusRequest * @return A Java Future containing the result of the DescribeRefreshSchemasStatus operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeRefreshSchemasStatus * @see AWS API Documentation */ @Override public CompletableFuture describeRefreshSchemasStatus( DescribeRefreshSchemasStatusRequest describeRefreshSchemasStatusRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeRefreshSchemasStatusResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeRefreshSchemasStatusRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeRefreshSchemasStatusRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about replication instances for your account in the current region. *

* * @param describeReplicationInstancesRequest * @return A Java Future containing the result of the DescribeReplicationInstances operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationInstances * @see AWS API Documentation */ @Override public CompletableFuture describeReplicationInstances( DescribeReplicationInstancesRequest describeReplicationInstancesRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeReplicationInstancesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeReplicationInstancesRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeReplicationInstancesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about replication instances for your account in the current region. *

*
*

* This is a variant of * {@link #describeReplicationInstances(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationInstancesRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationInstancesPublisher publisher = client.describeReplicationInstancesPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationInstancesPublisher publisher = client.describeReplicationInstancesPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationInstancesResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeReplicationInstances(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationInstancesRequest)} * operation. *

* * @param describeReplicationInstancesRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationInstances * @see AWS API Documentation */ public DescribeReplicationInstancesPublisher describeReplicationInstancesPaginator( DescribeReplicationInstancesRequest describeReplicationInstancesRequest) { return new DescribeReplicationInstancesPublisher(this, applyPaginatorUserAgent(describeReplicationInstancesRequest)); } /** *

* Returns information about the replication subnet groups. *

* * @param describeReplicationSubnetGroupsRequest * @return A Java Future containing the result of the DescribeReplicationSubnetGroups operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationSubnetGroups * @see AWS API Documentation */ @Override public CompletableFuture describeReplicationSubnetGroups( DescribeReplicationSubnetGroupsRequest describeReplicationSubnetGroupsRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeReplicationSubnetGroupsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeReplicationSubnetGroupsRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeReplicationSubnetGroupsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about the replication subnet groups. *

*
*

* This is a variant of * {@link #describeReplicationSubnetGroups(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationSubnetGroupsRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationSubnetGroupsPublisher publisher = client.describeReplicationSubnetGroupsPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationSubnetGroupsPublisher publisher = client.describeReplicationSubnetGroupsPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationSubnetGroupsResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeReplicationSubnetGroups(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationSubnetGroupsRequest)} * operation. *

* * @param describeReplicationSubnetGroupsRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationSubnetGroups * @see AWS API Documentation */ public DescribeReplicationSubnetGroupsPublisher describeReplicationSubnetGroupsPaginator( DescribeReplicationSubnetGroupsRequest describeReplicationSubnetGroupsRequest) { return new DescribeReplicationSubnetGroupsPublisher(this, applyPaginatorUserAgent(describeReplicationSubnetGroupsRequest)); } /** *

* Returns the task assessment results from Amazon S3. This action always returns the latest results. *

* * @param describeReplicationTaskAssessmentResultsRequest * @return A Java Future containing the result of the DescribeReplicationTaskAssessmentResults operation returned by * the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationTaskAssessmentResults * @see AWS API Documentation */ @Override public CompletableFuture describeReplicationTaskAssessmentResults( DescribeReplicationTaskAssessmentResultsRequest describeReplicationTaskAssessmentResultsRequest) { try { HttpResponseHandler responseHandler = protocolFactory .createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeReplicationTaskAssessmentResultsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeReplicationTaskAssessmentResultsRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeReplicationTaskAssessmentResultsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about replication tasks for your account in the current region. *

* * @param describeReplicationTasksRequest * @return A Java Future containing the result of the DescribeReplicationTasks operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationTasks * @see AWS * API Documentation */ @Override public CompletableFuture describeReplicationTasks( DescribeReplicationTasksRequest describeReplicationTasksRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeReplicationTasksResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeReplicationTasksRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeReplicationTasksRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about replication tasks for your account in the current region. *

*
*

* This is a variant of * {@link #describeReplicationTasks(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTasksRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationTasksPublisher publisher = client.describeReplicationTasksPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeReplicationTasksPublisher publisher = client.describeReplicationTasksPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTasksResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeReplicationTasks(software.amazon.awssdk.services.databasemigration.model.DescribeReplicationTasksRequest)} * operation. *

* * @param describeReplicationTasksRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeReplicationTasks * @see AWS * API Documentation */ public DescribeReplicationTasksPublisher describeReplicationTasksPaginator( DescribeReplicationTasksRequest describeReplicationTasksRequest) { return new DescribeReplicationTasksPublisher(this, applyPaginatorUserAgent(describeReplicationTasksRequest)); } /** *

* Returns information about the schema for the specified endpoint. *

*

* * @param describeSchemasRequest * @return A Java Future containing the result of the DescribeSchemas operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *

    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • ResourceNotFoundException The resource could not be found.
  • * SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can * be used for catch all scenarios.
  • SdkClientException If any client side error occurs such as an * IO related failure, failure to get credentials, etc.
  • DatabaseMigrationException Base class for * all service exceptions. Unknown exceptions will be thrown as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeSchemas * @see AWS API * Documentation */ @Override public CompletableFuture describeSchemas(DescribeSchemasRequest describeSchemasRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeSchemasResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new DescribeSchemasRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(describeSchemasRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns information about the schema for the specified endpoint. *

*

*
*

* This is a variant of * {@link #describeSchemas(software.amazon.awssdk.services.databasemigration.model.DescribeSchemasRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeSchemasPublisher publisher = client.describeSchemasPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeSchemasPublisher publisher = client.describeSchemasPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeSchemasResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeSchemas(software.amazon.awssdk.services.databasemigration.model.DescribeSchemasRequest)} * operation. *

* * @param describeSchemasRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeSchemas * @see AWS API * Documentation */ public DescribeSchemasPublisher describeSchemasPaginator(DescribeSchemasRequest describeSchemasRequest) { return new DescribeSchemasPublisher(this, applyPaginatorUserAgent(describeSchemasRequest)); } /** *

* Returns table statistics on the database migration task, including table name, rows inserted, rows updated, and * rows deleted. *

*

* Note that the "last updated" column the DMS console only indicates the time that AWS DMS last updated the table * statistics record for a table. It does not indicate the time of the last update to the table. *

* * @param describeTableStatisticsRequest * @return A Java Future containing the result of the DescribeTableStatistics operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeTableStatistics * @see AWS * API Documentation */ @Override public CompletableFuture describeTableStatistics( DescribeTableStatisticsRequest describeTableStatisticsRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new DescribeTableStatisticsResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new DescribeTableStatisticsRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(describeTableStatisticsRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Returns table statistics on the database migration task, including table name, rows inserted, rows updated, and * rows deleted. *

*

* Note that the "last updated" column the DMS console only indicates the time that AWS DMS last updated the table * statistics record for a table. It does not indicate the time of the last update to the table. *

*
*

* This is a variant of * {@link #describeTableStatistics(software.amazon.awssdk.services.databasemigration.model.DescribeTableStatisticsRequest)} * operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. * SDK will internally handle making service calls for you. *

*

* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet * and so there is no guarantee that the request is valid. If there are errors in your request, you will see the * failures only after you start streaming the data. The subscribe method should be called as a request to start * streaming data. For more info, see * {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe * method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the * starting request. *

* *

* The following are few ways to use the response class: *

* 1) Using the forEach helper method * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeTableStatisticsPublisher publisher = client.describeTableStatisticsPaginator(request);
     * CompletableFuture future = publisher.forEach(res -> { // Do something with the response });
     * future.get();
     * }
     * 
* * 2) Using a custom subscriber * *
     * {@code
     * software.amazon.awssdk.services.databasemigration.paginators.DescribeTableStatisticsPublisher publisher = client.describeTableStatisticsPaginator(request);
     * publisher.subscribe(new Subscriber() {
     * 
     * public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
     * 
     * 
     * public void onNext(software.amazon.awssdk.services.databasemigration.model.DescribeTableStatisticsResponse response) { //... };
     * });}
     * 
* * As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2. *

* Note: If you prefer to have control on service calls, use the * {@link #describeTableStatistics(software.amazon.awssdk.services.databasemigration.model.DescribeTableStatisticsRequest)} * operation. *

* * @param describeTableStatisticsRequest * @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.DescribeTableStatistics * @see AWS * API Documentation */ public DescribeTableStatisticsPublisher describeTableStatisticsPaginator( DescribeTableStatisticsRequest describeTableStatisticsRequest) { return new DescribeTableStatisticsPublisher(this, applyPaginatorUserAgent(describeTableStatisticsRequest)); } /** *

* Uploads the specified certificate. *

* * @param importCertificateRequest * @return A Java Future containing the result of the ImportCertificate operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • InvalidCertificateException The certificate was not valid.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ImportCertificate * @see AWS API * Documentation */ @Override public CompletableFuture importCertificate(ImportCertificateRequest importCertificateRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ImportCertificateResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new ImportCertificateRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(importCertificateRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Lists all tags for an AWS DMS resource. *

* * @param listTagsForResourceRequest * @return A Java Future containing the result of the ListTagsForResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ListTagsForResource * @see AWS API * Documentation */ @Override public CompletableFuture listTagsForResource( ListTagsForResourceRequest listTagsForResourceRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ListTagsForResourceResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new ListTagsForResourceRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(listTagsForResourceRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Modifies the specified endpoint. *

* * @param modifyEndpointRequest * @return A Java Future containing the result of the ModifyEndpoint operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • AccessDeniedException AWS DMS was denied access to the endpoint.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ModifyEndpoint * @see AWS API * Documentation */ @Override public CompletableFuture modifyEndpoint(ModifyEndpointRequest modifyEndpointRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ModifyEndpointResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new ModifyEndpointRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(modifyEndpointRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Modifies an existing AWS DMS event notification subscription. *

* * @param modifyEventSubscriptionRequest * @return A Java Future containing the result of the ModifyEventSubscription operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SnsInvalidTopicException The SNS topic is invalid.
  • *
  • SnsNoAuthorizationException You are not authorized for the SNS subscription.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ModifyEventSubscription * @see AWS * API Documentation */ @Override public CompletableFuture modifyEventSubscription( ModifyEventSubscriptionRequest modifyEventSubscriptionRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ModifyEventSubscriptionResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new ModifyEventSubscriptionRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(modifyEventSubscriptionRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Modifies the replication instance to apply new settings. You can change one or more parameters by specifying * these parameters and the new values in the request. *

*

* Some settings are applied during the maintenance window. *

*

* * @param modifyReplicationInstanceRequest * @return A Java Future containing the result of the ModifyReplicationInstance operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *

    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • ResourceAlreadyExistsException The resource you are attempting to create * already exists.
  • ResourceNotFoundException The resource could not be found.
  • * InsufficientResourceCapacityException There are not enough resources allocated to the database migration. *
  • StorageQuotaExceededException The storage quota has been exceeded.
  • * UpgradeDependencyFailureException An upgrade dependency is preventing the database migration.
  • * SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can * be used for catch all scenarios.
  • SdkClientException If any client side error occurs such as an * IO related failure, failure to get credentials, etc.
  • DatabaseMigrationException Base class for * all service exceptions. Unknown exceptions will be thrown as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ModifyReplicationInstance * @see AWS * API Documentation */ @Override public CompletableFuture modifyReplicationInstance( ModifyReplicationInstanceRequest modifyReplicationInstanceRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ModifyReplicationInstanceResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new ModifyReplicationInstanceRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(modifyReplicationInstanceRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Modifies the settings for the specified replication subnet group. *

* * @param modifyReplicationSubnetGroupRequest * @return A Java Future containing the result of the ModifyReplicationSubnetGroup operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • AccessDeniedException AWS DMS was denied access to the endpoint.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • SubnetAlreadyInUseException The specified subnet is already in use.
  • *
  • ReplicationSubnetGroupDoesNotCoverEnoughAZsException The replication subnet group does not cover * enough Availability Zones (AZs). Edit the replication subnet group and add more AZs.
  • *
  • InvalidSubnetException The subnet provided is invalid.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ModifyReplicationSubnetGroup * @see AWS API Documentation */ @Override public CompletableFuture modifyReplicationSubnetGroup( ModifyReplicationSubnetGroupRequest modifyReplicationSubnetGroupRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ModifyReplicationSubnetGroupResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new ModifyReplicationSubnetGroupRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(modifyReplicationSubnetGroupRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Modifies the specified replication task. *

*

* You can't modify the task endpoints. The task must be stopped before you can modify it. *

*

* For more information about AWS DMS tasks, see the AWS DMS user guide at Working with Migration Tasks *

* * @param modifyReplicationTaskRequest * @return A Java Future containing the result of the ModifyReplicationTask operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • ResourceAlreadyExistsException The resource you are attempting to create already exists.
  • *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ModifyReplicationTask * @see AWS API * Documentation */ @Override public CompletableFuture modifyReplicationTask( ModifyReplicationTaskRequest modifyReplicationTaskRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ModifyReplicationTaskResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new ModifyReplicationTaskRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(modifyReplicationTaskRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Populates the schema for the specified endpoint. This is an asynchronous operation and can take several minutes. * You can check the status of this operation by calling the DescribeRefreshSchemasStatus operation. *

* * @param refreshSchemasRequest * @return A Java Future containing the result of the RefreshSchemas operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.RefreshSchemas * @see AWS API * Documentation */ @Override public CompletableFuture refreshSchemas(RefreshSchemasRequest refreshSchemasRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new RefreshSchemasResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new RefreshSchemasRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(refreshSchemasRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Reloads the target database table with the source data. *

* * @param reloadTablesRequest * @return A Java Future containing the result of the ReloadTables operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.ReloadTables * @see AWS API * Documentation */ @Override public CompletableFuture reloadTables(ReloadTablesRequest reloadTablesRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new ReloadTablesResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new ReloadTablesRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(reloadTablesRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Removes metadata tags from a DMS resource. *

* * @param removeTagsFromResourceRequest * @return A Java Future containing the result of the RemoveTagsFromResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.RemoveTagsFromResource * @see AWS API * Documentation */ @Override public CompletableFuture removeTagsFromResource( RemoveTagsFromResourceRequest removeTagsFromResourceRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new RemoveTagsFromResourceResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new RemoveTagsFromResourceRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(removeTagsFromResourceRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Starts the replication task. *

*

* For more information about AWS DMS tasks, see the AWS DMS user guide at Working with Migration Tasks *

* * @param startReplicationTaskRequest * @return A Java Future containing the result of the StartReplicationTask operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.StartReplicationTask * @see AWS API * Documentation */ @Override public CompletableFuture startReplicationTask( StartReplicationTaskRequest startReplicationTaskRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new StartReplicationTaskResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new StartReplicationTaskRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(startReplicationTaskRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Starts the replication task assessment for unsupported data types in the source database. *

* * @param startReplicationTaskAssessmentRequest * @return A Java Future containing the result of the StartReplicationTaskAssessment operation returned by the * service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • ResourceNotFoundException The resource could not be found.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.StartReplicationTaskAssessment * @see AWS API Documentation */ @Override public CompletableFuture startReplicationTaskAssessment( StartReplicationTaskAssessmentRequest startReplicationTaskAssessmentRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new StartReplicationTaskAssessmentResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler .execute(new ClientExecutionParams() .withMarshaller(new StartReplicationTaskAssessmentRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(startReplicationTaskAssessmentRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Stops the replication task. *

*

* * @param stopReplicationTaskRequest * @return A Java Future containing the result of the StopReplicationTask operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *

    *
  • ResourceNotFoundException The resource could not be found.
  • InvalidResourceStateException The * resource is in a state that prevents it from being used for database migration.
  • SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios.
  • SdkClientException If any client side error occurs such as an IO related * failure, failure to get credentials, etc.
  • DatabaseMigrationException Base class for all service * exceptions. Unknown exceptions will be thrown as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.StopReplicationTask * @see AWS API * Documentation */ @Override public CompletableFuture stopReplicationTask( StopReplicationTaskRequest stopReplicationTaskRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new StopReplicationTaskResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new StopReplicationTaskRequestMarshaller(protocolFactory)) .withResponseHandler(responseHandler).withErrorResponseHandler(errorResponseHandler) .withInput(stopReplicationTaskRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } /** *

* Tests the connection between the replication instance and the endpoint. *

* * @param testConnectionRequest * @return A Java Future containing the result of the TestConnection operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following * exceptions. *
    *
  • ResourceNotFoundException The resource could not be found.
  • *
  • InvalidResourceStateException The resource is in a state that prevents it from being used for * database migration.
  • *
  • KmsKeyNotAccessibleException AWS DMS cannot access the KMS key.
  • *
  • ResourceQuotaExceededException The quota for this resource quota has been exceeded.
  • *
  • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). * Can be used for catch all scenarios.
  • *
  • SdkClientException If any client side error occurs such as an IO related failure, failure to get * credentials, etc.
  • *
  • DatabaseMigrationException Base class for all service exceptions. Unknown exceptions will be thrown * as an instance of this type.
  • *
* @sample DatabaseMigrationAsyncClient.TestConnection * @see AWS API * Documentation */ @Override public CompletableFuture testConnection(TestConnectionRequest testConnectionRequest) { try { HttpResponseHandler responseHandler = protocolFactory.createResponseHandler( new JsonOperationMetadata().withPayloadJson(true).withHasStreamingSuccessResponse(false), new TestConnectionResponseUnmarshaller()); HttpResponseHandler errorResponseHandler = createErrorResponseHandler(); return clientHandler.execute(new ClientExecutionParams() .withMarshaller(new TestConnectionRequestMarshaller(protocolFactory)).withResponseHandler(responseHandler) .withErrorResponseHandler(errorResponseHandler).withInput(testConnectionRequest)); } catch (Throwable t) { return CompletableFutureUtils.failedFuture(t); } } @Override public void close() { clientHandler.close(); } private software.amazon.awssdk.awscore.protocol.json.AwsJsonProtocolFactory init() { return new AwsJsonProtocolFactory(new JsonClientMetadata() .withSupportsCbor(false) .withSupportsIon(false) .withBaseServiceExceptionClass( software.amazon.awssdk.services.databasemigration.model.DatabaseMigrationException.class) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("InvalidCertificateFault").withModeledClass( InvalidCertificateException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("UpgradeDependencyFailureFault").withModeledClass( UpgradeDependencyFailureException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("KMSKeyNotAccessibleFault").withModeledClass( KmsKeyNotAccessibleException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("SNSInvalidTopicFault").withModeledClass( SnsInvalidTopicException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("InsufficientResourceCapacityFault").withModeledClass( InsufficientResourceCapacityException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ResourceQuotaExceededFault").withModeledClass( ResourceQuotaExceededException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("AccessDeniedFault").withModeledClass( AccessDeniedException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("InvalidResourceStateFault").withModeledClass( InvalidResourceStateException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ResourceNotFoundFault").withModeledClass( ResourceNotFoundException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("SNSNoAuthorizationFault").withModeledClass( SnsNoAuthorizationException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("SubnetAlreadyInUse").withModeledClass( SubnetAlreadyInUseException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ResourceAlreadyExistsFault").withModeledClass( ResourceAlreadyExistsException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("InvalidSubnet") .withModeledClass(InvalidSubnetException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("StorageQuotaExceededFault").withModeledClass( StorageQuotaExceededException.class)) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ReplicationSubnetGroupDoesNotCoverEnoughAZs") .withModeledClass(ReplicationSubnetGroupDoesNotCoverEnoughAZsException.class)), AwsJsonProtocolMetadata.builder().protocolVersion("1.1").protocol(AwsJsonProtocol.AWS_JSON).build()); } private T applyPaginatorUserAgent(T request) { Consumer userAgentApplier = b -> b.addApiName(ApiName.builder() .version(VersionInfo.SDK_VERSION).name("PAGINATED").build()); AwsRequestOverrideConfiguration overrideConfiguration = request.overrideConfiguration() .map(c -> c.toBuilder().applyMutation(userAgentApplier).build()) .orElse((AwsRequestOverrideConfiguration.builder().applyMutation(userAgentApplier).build())); return (T) request.toBuilder().overrideConfiguration(overrideConfiguration).build(); } private HttpResponseHandler createErrorResponseHandler() { return protocolFactory.createErrorResponseHandler(new JsonErrorResponseMetadata()); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy