aws-cloudformation / aws-cloudformation/cloudformation-cli-java-plugin

Auto map Amazon exception into CFN exception to reduce handler exception mapping

未关闭
#353 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement
主要语言
Java
星标
30
派生
48
PR 合并指标
30 天内没有已合并 PR

描述

Cloudformation will do retry for retriable exception, such as throttling exception. However, it requires each handler to map the exception into CFN throttling error.

We should be able to auto map the exception to reduce the effort for all resource to map it. For example:

```java
...................
} catch (AmazonServiceException ex) {
if (RetryUtils.isThrottlingException(ex)) {
logger.log(String.format("%s [%s] Create call throttled by downstream service", ResourceModel.TYPE_NAME, model.getAlarmName()));
return ProgressEvent.defaultFailureHandler(ex, HandlerErrorCode.Throttling);
}
..................
}

```

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。