@SdkInternalApi
    final AssociateTransitGatewayMulticastDomainResult executeAssociateTransitGatewayMulticastDomain(
            AssociateTransitGatewayMulticastDomainRequest associateTransitGatewayMulticastDomainRequest) {

        ExecutionContext executionContext = createExecutionContext(associateTransitGatewayMulticastDomainRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<AssociateTransitGatewayMulticastDomainRequest> request = null;
        Response<AssociateTransitGatewayMulticastDomainResult> response = null;

        try {
            awsRequestMetrics.startEvent(Field.RequestMarshallTime);
            try {
                request = new AssociateTransitGatewayMulticastDomainRequestMarshaller().marshall(super
                        .beforeMarshalling(associateTransitGatewayMulticastDomainRequest));
                // Binds the request metrics to the current request.
                request.setAWSRequestMetrics(awsRequestMetrics);
                request.addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint);
                request.addHandlerContext(HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden());
                request.addHandlerContext(HandlerContextKey.SIGNING_REGION, getSigningRegion());
                request.addHandlerContext(HandlerContextKey.SERVICE_ID, "EC2");
                request.addHandlerContext(HandlerContextKey.OPERATION_NAME, "AssociateTransitGatewayMulticastDomain");
                request.addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig);

            } finally {
                awsRequestMetrics.endEvent(Field.RequestMarshallTime);
            }

            StaxResponseHandler<AssociateTransitGatewayMulticastDomainResult> responseHandler = new StaxResponseHandler<AssociateTransitGatewayMulticastDomainResult>(
                    new AssociateTransitGatewayMulticastDomainResultStaxUnmarshaller());

            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Associates the specified subnets and transit gateway attachments with the specified transit gateway multicast
domain.
</p>
<p>
The transit gateway attachment must be in the available state before you can add a resource. Use <a
href="https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeTransitGatewayAttachments.html"
>DescribeTransitGatewayAttachments</a> to see the state of the attachment.
</p>

@param associateTransitGatewayMulticastDomainRequest
@return Result of the AssociateTransitGatewayMulticastDomain operation returned by the service.
@sample AmazonEC2.AssociateTransitGatewayMulticastDomain
@see <a href="http://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AssociateTransitGatewayMulticastDomain"
     target="_top">AWS API Documentation</a>
aws-java-sdk-ec2/src/main/java/com/amazonaws/services/ec2/AmazonEC2Client.java