@SdkInternalApi
    final CreateCarrierGatewayResult executeCreateCarrierGateway(CreateCarrierGatewayRequest createCarrierGatewayRequest) {

        ExecutionContext executionContext = createExecutionContext(createCarrierGatewayRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<CreateCarrierGatewayRequest> request = null;
        Response<CreateCarrierGatewayResult> response = null;

        try {
            awsRequestMetrics.startEvent(Field.RequestMarshallTime);
            try {
                request = new CreateCarrierGatewayRequestMarshaller().marshall(super.beforeMarshalling(createCarrierGatewayRequest));
                // 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, "CreateCarrierGateway");
                request.addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig);

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

            StaxResponseHandler<CreateCarrierGatewayResult> responseHandler = new StaxResponseHandler<CreateCarrierGatewayResult>(
                    new CreateCarrierGatewayResultStaxUnmarshaller());

            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Creates a carrier gateway. For more information about carrier gateways, see <a href=
"https://docs.aws.amazon.com/wavelength/latest/developerguide/how-wavelengths-work.html#wavelength-carrier-gateway"
>Carrier gateways</a> in the <i>Amazon Web Services Wavelength Developer Guide</i>.
</p>

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