@SdkInternalApi
    final UnassignPrivateNatGatewayAddressResult executeUnassignPrivateNatGatewayAddress(
            UnassignPrivateNatGatewayAddressRequest unassignPrivateNatGatewayAddressRequest) {

        ExecutionContext executionContext = createExecutionContext(unassignPrivateNatGatewayAddressRequest);
        AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
        awsRequestMetrics.startEvent(Field.ClientExecuteTime);
        Request<UnassignPrivateNatGatewayAddressRequest> request = null;
        Response<UnassignPrivateNatGatewayAddressResult> response = null;

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

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

            StaxResponseHandler<UnassignPrivateNatGatewayAddressResult> responseHandler = new StaxResponseHandler<UnassignPrivateNatGatewayAddressResult>(
                    new UnassignPrivateNatGatewayAddressResultStaxUnmarshaller());

            response = invoke(request, responseHandler, executionContext);

            return response.getAwsResponse();

        } finally {

            endClientExecution(awsRequestMetrics, request, response);
        }
    }
<p>
Unassigns secondary private IPv4 addresses from a private NAT gateway. You cannot unassign your primary private
IP. For more information, see <a
href="https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html#nat-gateway-edit-secondary">Edit
secondary IP address associations</a> in the <i>Amazon VPC User Guide</i>.
</p>
<p>
While unassigning is in progress, you cannot assign/unassign additional IP addresses while the connections are
being drained. You are, however, allowed to delete the NAT gateway.
</p>
<p>
A private IP address will only be released at the end of MaxDrainDurationSeconds. The private IP addresses stay
associated and support the existing connections, but do not support any new connections (new connections are
distributed across the remaining assigned private IP address). After the existing connections drain out, the
private IP addresses are released.
</p>
<p/>
<p/>

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