将消息从Azure事件中心路由到Azure Service Bus [英] Routing Messages from Azure Event Hub to Azure Service Bus

查看:71
本文介绍了将消息从Azure事件中心路由到Azure Service Bus的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以自动将事件从Azure Event Hub路由/重定向到Azure Service Bus







基本上我想拥有一个系统范围(由整个公司使用)事件中心和特定系统的服务总线(系统X)(由多个服务组成)



而不是开发一个从Azure事件中心读取并写入的服务到Azure Service Bus(System X Event Gateway),我想知道是否有办法在Azure中配置这样的东西。



我知道它是Azure Logic Apps有点可能,但我怀疑它的性能,我需要立即路由消息,在Logic Apps中默认的间隔是3分钟。我也不知道这是否是最好的方法,可能还有另一个我不知道的
Azure产品。



什么你建议吗?

Is it possible to automatically route/redirect events from Azure Event Hub to Azure Service Bus



Basically i want to have a system-wide (used by the entire company) event hub and a service bus for a specific system (System X) (which is composed of multiple services)

Instead of developing a service that would read from Azure Event Hub and write to Azure Service Bus (System X Event Gateway), i would like to know whether there is a way to configure something like this in Azure.

I know that it is somewhat possible with Azure Logic Apps, but i doubt its performance, i need the messages to be routed immediately and in Logic Apps the default interval is 3 minutes. I also don't know whether it is the best way to do it, there might be another Azure product that i'm unaware of.

What do you suggest?

推荐答案

虽然事件中心触发器有一个重复设置,但它的工作方式有点不同,如最后的注释所述这个  部分 
文档。

Though the Event Hubs Trigger has a recurrence setting, the way it works is a bit different as mentioned in the note at the end of this section of the docs.

引用那里 -  

所有活动集线器触发器是长轮询触发器,这意味着当触发器触发时,触发器会处理所有事件,然后等待30秒,以便在事件中心中显示更多事件。如果在30秒内未收到任何事件,则跳过触发器
run。否则,触发器将继续读取事件,直到您的Event Hub为空。下一次触发轮询是根据您在触发器属性中指定的重复间隔发生的。

To quote that there - 
All Event Hub triggers are long-polling triggers, which means that when a trigger fires, the trigger processes all the events and then waits for 30 seconds for more events to appear in your Event Hub. If no events are received in 30 seconds, the trigger run is skipped. Otherwise, the trigger continues reading events until your Event Hub is empty. The next trigger poll happens based on the recurrence interval that you specify in the trigger's properties.

因此,3分钟等待仅在事件中心变空但30秒时是< 实际  最低。

So, the 3 mins wait is only when Event Hubs has become empty but 30 seconds is the actual minimum.

即使如此,我认为Logic Apps最适合您的用例。您最好建立自己的消费者,不断将数据从事件中心复制到服务总线。

Even still, I don't think Logic Apps are best suited for your use case. You are better off building your own consumer continuously copying data from event hubs to service bus.

AFAIK没有适合您的用例的任何内置服务。

AFAIK there isn't any built-in service available for you which fits your use case.

但话又说回来,我不确定您的确切用例,但假设事件中心和服务总线的标准用例,

Azure流分析
是您想要查看的内容。它支持
来自事件中心的流数据

输出到服务总线


But then again, I'm unsure of your exact use case but assuming standard use cases of Event Hubs and Service Bus, Azure Stream Analytics is something that you'd want to look at. It supports streaming data from Event Hubs and output to Service Bus.

我想你应该能够实现你的用例是通过 而不是 转换数据并转发它但我从未真正尝试过这个。

I guess you should be able to achieve your use case by not transforming data and just forwarding it but I've never really tried this.


这篇关于将消息从Azure事件中心路由到Azure Service Bus的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆