@SdkInternalApi
    final DeleteOriginRequestPolicyResult executeDeleteOriginRequestPolicy(DeleteOriginRequestPolicyRequest deleteOriginRequestPolicyRequest) {

        ExecutionContext executionContext = createExecutionContext(deleteOriginRequestPolicyRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<DeleteOriginRequestPolicyRequest> request = null;
        Response<DeleteOriginRequestPolicyResult> response = null;

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

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

            StaxResponseHandler<DeleteOriginRequestPolicyResult> responseHandler = new StaxResponseHandler<DeleteOriginRequestPolicyResult>(
                    new DeleteOriginRequestPolicyResultStaxUnmarshaller());

            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Deletes an origin request policy.
</p>
<p>
You cannot delete an origin request policy if it's attached to any cache behaviors. First update your
distributions to remove the origin request policy from all cache behaviors, then delete the origin request
policy.
</p>
<p>
To delete an origin request policy, you must provide the policy's identifier and version. To get the identifier,
you can use <code>ListOriginRequestPolicies</code> or <code>GetOriginRequestPolicy</code>.
</p>

@param deleteOriginRequestPolicyRequest
@return Result of the DeleteOriginRequestPolicy operation returned by the service.
@throws AccessDeniedException
        Access denied.
@throws InvalidIfMatchVersionException
        The <code>If-Match</code> version is missing or not valid.
@throws NoSuchOriginRequestPolicyException
        The origin request policy does not exist.
@throws PreconditionFailedException
        The precondition in one or more of the request fields evaluated to <code>false</code>.
@throws IllegalDeleteException
        You cannot delete a managed policy.
@throws OriginRequestPolicyInUseException
        Cannot delete the origin request policy because it is attached to one or more cache behaviors.
@sample AmazonCloudFront.DeleteOriginRequestPolicy
@see <a href="http://docs.aws.amazon.com/goto/WebAPI/cloudfront-2020-05-31/DeleteOriginRequestPolicy"
     target="_top">AWS API Documentation</a>
aws-java-sdk-cloudfront/src/main/java/com/amazonaws/services/cloudfront/AmazonCloudFrontClient.java