Amazon SNS http 端点在非 4xx http 状态代码上重试

Amazon SNS http endpoint retry on non 4xx http status code

SNS 似乎仅在端点 returns 首次尝试时为 5xx 代码时才重试传递到 http(s) 端点。 如果端点 returns 4xx 错误代码也是如此,是否可以使用 SNS 配置 http 订阅以允许重试?

暂时不会,确认订阅后SNS不会将2xx-4xx视为服务器错误,

文档中的第 5 步证实了这一点:

  1. Make sure that your endpoint responds to the HTTP POST message from Amazon SNS with the appropriate status code. The connection will time out in 15 seconds. If your endpoint does not respond before the connection times out or if your endpoint returns a status code outside the range of 200–4xx, Amazon SNS will consider the delivery of the message as a failed attempt.

https://docs.aws.amazon.com/sns/latest/dg/SendMessageToHttp.prepare.html