几种风暴拓扑之间的通信 [英] Communication Between Several Storm Topologies

查看:96
本文介绍了几种风暴拓扑之间的通信的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在生产中部署几种Storm拓扑.我检查了文档,但找不到有关拓扑是否有可能通过本机方法进行通信的任何参考.有人对如何实施有任何建议吗?

I am trying to deploy several Storm topologies in production. I checked the documentation but couldn't find any references on whether it is possible for the topologies to communicate via native methods. Does anyone have any suggestions on how this could be implemented?

简而言之,我很想看看是否有可能在拓扑之间发送元组.

In short, I am interested to see if the it's possible for tuples to be sent across topologies.

感谢您的帮助!

推荐答案

从理论上讲,您可能会实现它.实际上,不是.

Theoretically, you could probably make it happen. Practically, no.

如果要通过元组进行通信,则应该在一个拓扑中进行所有操作.拓扑组织的是计算而不是代码,因此,您要一起计算的所有内容都应该放在拓扑中.

If you want to communicate via tuples, you should be doing that all in one topology. Topologies organize computation not code, so all the stuff that you want to compute together should go together in the topology.

也就是说,在某些情况下,由于计算各部分的性质可能非常不同,因此您希望将计算划分为各种拓扑.在这种情况下,您将需要使用外部消息传递服务来切换拓扑之间的工作.老实说,这比尝试在拓扑之间直接传递元组要容易和稳定得多.使用Redis取得了很大的成功.

That said, there are cases when you will want to split computations across topologies because of the possibly very different nature of each part of the computation. In such a case you will need to use an outside message passing service to hand off work between topologies. This is honestly way easier and more robust than trying to pass tuples directly between topologies. I have had great success using Redis.

这篇关于几种风暴拓扑之间的通信的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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