Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/asp.net-core/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Docker 与Azure事件中心的Dapr输入绑定同步处理消息_Docker_Asp.net Core_Azure Aks_Azure Eventhub_Dapr - Fatal编程技术网

Docker 与Azure事件中心的Dapr输入绑定同步处理消息

Docker 与Azure事件中心的Dapr输入绑定同步处理消息,docker,asp.net-core,azure-aks,azure-eventhub,dapr,Docker,Asp.net Core,Azure Aks,Azure Eventhub,Dapr,我们正在使用dapr和输入绑定来使用Azure事件中心的IoT事件。 事件中心有32个分区,发送方使用设备id作为分区密钥。 接收事件的控制器将事件委托给dapr参与者进行处理 现在我的期望是,每个分区中的消息都是并行处理的,这会导致对控制器的并行请求接收事件,从而允许处理多达32个并发事件批 然而,测试表明这些事件是同步接收的。在前一个事件的完整处理刚刚完成之后,将接收后续事件 现在我知道actors是通过设计一个接一个地处理消息的,但是我没有读过关于输入绑定的类似内容 有什么我完全不知道的吗

我们正在使用dapr和输入绑定来使用Azure事件中心的IoT事件。 事件中心有32个分区,发送方使用设备id作为分区密钥。 接收事件的控制器将事件委托给dapr参与者进行处理

现在我的期望是,每个分区中的消息都是并行处理的,这会导致对控制器的并行请求接收事件,从而允许处理多达32个并发事件批

然而,测试表明这些事件是同步接收的。在前一个事件的完整处理刚刚完成之后,将接收后续事件

现在我知道actors是通过设计一个接一个地处理消息的,但是我没有读过关于输入绑定的类似内容

有什么我完全不知道的吗?否则,我无法想象这个系统如何扩展


我们正在使用dapr 0.11以及在AKS集群中运行的ASP.NET Core 3.1。

我刚刚在GitHub上得到了一个答案:

因此,这基本上证实了我基于当前版本的dapr事件中心绑定的观察结果

但是,您可以手动配置每个dapr组件的分区ID。因此,要同时读取32个分区,您当前必须使用32个dapr组件,每个组件从一个单独的分区读取

引用上述GitHub问题:

[...] you can specify a Dapr component per partition ID: https://docs.dapr.io/operations/components/setup-bindings/supported-bindings/eventhubs/

If you set the partitionID field on the component metadata, the consumer will pull all messages for that partition ID.
Otherwise, it'll pull from all partitions.