private DeleteGrantResponse deleteGrant()

in aws-licensemanager-grant/src/main/java/software/amazon/licensemanager/grant/DeleteHandler.java [72:91]


    private DeleteGrantResponse deleteGrant(
            final ResourceModel model,
            final DeleteGrantRequest deleteGrantRequest,
            final ProxyClient<LicenseManagerClient> proxyClient) {
        DeleteGrantResponse deleteGrantResponse = null;
        try {

            deleteGrantResponse = proxyClient.injectCredentialsAndInvokeV2(deleteGrantRequest,
                    proxyClient.client()::deleteGrant);
        } catch (InvalidParameterValueException | ValidationException e) {
            logger.log("Resource deletion failed");
            throw new CfnNotFoundException(model.getGrantArn(), ResourceModel.TYPE_NAME);
        } catch (final AwsServiceException e) {
            logger.log("Resource deletion failed");
            throw new CfnGeneralServiceException(ResourceModel.TYPE_NAME + e.getMessage(), e);
        }

        logger.log(String.format("%s successfully deleted.", ResourceModel.TYPE_NAME));
        return deleteGrantResponse;
    }