@SdkInternalApi
    final CreateMonitoringSubscriptionResult executeCreateMonitoringSubscription(CreateMonitoringSubscriptionRequest createMonitoringSubscriptionRequest) {

        ExecutionContext executionContext = createExecutionContext(createMonitoringSubscriptionRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<CreateMonitoringSubscriptionRequest> request = null;
        Response<CreateMonitoringSubscriptionResult> response = null;

        try {
            awsRequestMetrics.startEvent(Field.RequestMarshallTime);
            try {
                request = new CreateMonitoringSubscriptionRequestMarshaller().marshall(super.beforeMarshalling(createMonitoringSubscriptionRequest));
                // 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, "CloudFront");
                request.addHandlerContext(HandlerContextKey.OPERATION_NAME, "CreateMonitoringSubscription");
                request.addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig);

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

            StaxResponseHandler<CreateMonitoringSubscriptionResult> responseHandler = new StaxResponseHandler<CreateMonitoringSubscriptionResult>(
                    new CreateMonitoringSubscriptionResultStaxUnmarshaller());

            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Enables additional CloudWatch metrics for the specified CloudFront distribution. The additional metrics incur an
additional cost.
</p>
<p>
For more information, see <a href=
"https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/viewing-cloudfront-metrics.html#monitoring-console.distributions-additional"
>Viewing additional CloudFront distribution metrics</a> in the <i>Amazon CloudFront Developer Guide</i>.
</p>

@param createMonitoringSubscriptionRequest
@return Result of the CreateMonitoringSubscription operation returned by the service.
@throws AccessDeniedException
        Access denied.
@throws NoSuchDistributionException
        The specified distribution does not exist.
@throws MonitoringSubscriptionAlreadyExistsException
        A monitoring subscription already exists for the specified distribution.
@throws UnsupportedOperationException
        This operation is not supported in this region.
@sample AmazonCloudFront.CreateMonitoringSubscription
@see <a href="http://docs.aws.amazon.com/goto/WebAPI/cloudfront-2020-05-31/CreateMonitoringSubscription"
     target="_top">AWS API Documentation</a>
aws-java-sdk-cloudfront/src/main/java/com/amazonaws/services/cloudfront/AmazonCloudFrontClient.java