in costcategory/src/main/java/software/amazon/ce/costcategory/DeleteHandler.java [27:47]
public ProgressEvent<ResourceModel, CallbackContext> handleRequest(
final AmazonWebServicesClientProxy proxy,
final ResourceHandlerRequest<ResourceModel> request,
final CallbackContext callbackContext,
final Logger logger) {
final ResourceModel model = request.getDesiredResourceState();
try {
proxy.injectCredentialsAndInvokeV2(
CostCategoryRequestBuilder.buildDeleteRequest(model),
costExplorerClient::deleteCostCategoryDefinition
);
} catch (ResourceNotFoundException ex) {
throw new CfnNotFoundException(ex);
}
return ProgressEvent.<ResourceModel, CallbackContext>builder()
.status(OperationStatus.SUCCESS)
.build();
}