@SdkInternalApi
    final GetOriginAccessControlResult executeGetOriginAccessControl(GetOriginAccessControlRequest getOriginAccessControlRequest) {

        ExecutionContext executionContext = createExecutionContext(getOriginAccessControlRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<GetOriginAccessControlRequest> request = null;
        Response<GetOriginAccessControlResult> response = null;

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

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

            StaxResponseHandler<GetOriginAccessControlResult> responseHandler = new StaxResponseHandler<GetOriginAccessControlResult>(
                    new GetOriginAccessControlResultStaxUnmarshaller());

            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Gets a CloudFront origin access control, including its unique identifier.
</p>

@param getOriginAccessControlRequest
@return Result of the GetOriginAccessControl operation returned by the service.
@throws NoSuchOriginAccessControlException
        The origin access control does not exist.
@throws AccessDeniedException
        Access denied.
@sample AmazonCloudFront.GetOriginAccessControl
@see <a href="http://docs.aws.amazon.com/goto/WebAPI/cloudfront-2020-05-31/GetOriginAccessControl"
     target="_top">AWS API Documentation</a>
aws-java-sdk-cloudfront/src/main/java/com/amazonaws/services/cloudfront/AmazonCloudFrontClient.java