Eventbridge - 使用 FIFO SQS 进行重复数据删除
Eventbridge - Use FIFO SQS for deduplication
我需要一些事件只传递一次,但我无法控制消息处理器(所以我不能使接收者幂等)。
是否可以将事件从 Eventbridge 路由到 FIFO SQS 以进行重复数据删除,并从 FIFO sqs 路由到接收方(其他帐户上的 lambda?这会实现精确一次交付吗?
EventBridge (EB) 有 at-least-once deliver which means you can get more then one event of the same type. But if this is not an issue, and your only concern is SQS, then yes, EB supports SQS FIFO 个目标:
EventBridge lets you set a variety of targets—such as Amazon SQS standard and FIFO queues—which receive events in JSON format.
可以,但是必须配置FIFO队列。它可以根据邮件正文检测重复项。看到这个 docs.
FIFO queues help you avoid sending duplicates to a queue. If you retry
the SendMessage action within the 5-minute deduplication interval,
Amazon SQS doesn't introduce any duplicates into the queue.
link接着说明了需要哪些配置,一定要查看一下。
当您将 SQS FIFO 设置为您的 EventBridge 规则的目标时,您能否从负载内容中动态设置 messageGroupId?
从目前的设置来看,我发现它只能是一个硬编码值。
我需要一些事件只传递一次,但我无法控制消息处理器(所以我不能使接收者幂等)。
是否可以将事件从 Eventbridge 路由到 FIFO SQS 以进行重复数据删除,并从 FIFO sqs 路由到接收方(其他帐户上的 lambda?这会实现精确一次交付吗?
EventBridge (EB) 有 at-least-once deliver which means you can get more then one event of the same type. But if this is not an issue, and your only concern is SQS, then yes, EB supports SQS FIFO 个目标:
EventBridge lets you set a variety of targets—such as Amazon SQS standard and FIFO queues—which receive events in JSON format.
可以,但是必须配置FIFO队列。它可以根据邮件正文检测重复项。看到这个 docs.
FIFO queues help you avoid sending duplicates to a queue. If you retry the SendMessage action within the 5-minute deduplication interval, Amazon SQS doesn't introduce any duplicates into the queue.
link接着说明了需要哪些配置,一定要查看一下。
当您将 SQS FIFO 设置为您的 EventBridge 规则的目标时,您能否从负载内容中动态设置 messageGroupId?
从目前的设置来看,我发现它只能是一个硬编码值。