本文介绍了AWS Lambda是否严格按顺序处理DynamoDB流事件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在编写一个Lambda函数来处理DynamoDB流中的项目。

I'm in the process of writing a Lambda function that processes items from a DynamoDB stream.

我认为Lambda背后的部分意思是,如果我有如果发生大量事件,它将启动足够多的实例以同时通过它们,而不是通过单个实例顺序地提供它们。只要两个事件具有不同的键,就可以对它们进行无序处理。

I thought part of the point behind Lambda was that if I have a large burst of events, it'll spin up enough instances to get through them concurrently, rather than feeding them sequentially through a single instance. As long as two events have a different key, I am fine with them being processed out of order.

但是,我只是在,其中说:

However, I just read this page on Understanding Retry Behavior, which says:

是否 AWS Lambda按顺序处理流事件意味着Lambda无法处理同时发生多个事件?有什么方法可以使其同时处理来自不同键的事件?

Does "AWS Lambda processes the stream events in order" mean Lambda cannot process multiple events concurrently? Is there any way to have it process events from distinct keys concurrently?

推荐答案

流记录被组织为组或碎片。

Stream records are organized into groups, or shards.

根据Lambda ,并发是在分片级别实现的。在每个分片中,按顺序处理流事件。

According to Lambda documentation, the concurrency is achieved on shard-level. Within each shard, the stream events are processed in order.

并根据,

这篇关于AWS Lambda是否严格按顺序处理DynamoDB流事件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-22 20:31
查看更多