zeromq

ActiveMQ或RabbitMQ或ZeroMQ或[关闭]

浪尽此生 提交于 2019-12-28 20:54:19
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> 我们有兴趣听听ActiveMQ与RabbitMQ和ZeroMQ的优缺点。 还欢迎有关任何其他有趣的消息队列的信息。 #1楼 还有的RabbitMQ和ActiveMQ的之间的比较 在这里 。 开箱即用,ActiveMQ配置为保证消息传递 - 与不太可靠的消息传递系统相比,这会给人留下缓慢的印象。 如果您愿意,您可以随时更改性能配置,并获得至少与其他任何邮件系统一样的性能。 至少你有这个选择。 有关论坛和ActiveMQ常见问题解答的大量信息,用于配置扩展,性能和高可用性。 此外,ActiveMQ将在规范最终确定时支持AMQP 1.0,以及其他有线格式,如STOMP。 ActiveMQ的另一个好处是它的Apache项目,因此开发人员社区存在多样性 - 而且它与一家公司无关。 #2楼 我只能加上关于ActiveMQ的2美分,但因为这是最流行的一个: 您想要写的语言可能很重要。 尽管ActiveMQ确实拥有大多数客户端,但与Java库相比,它们的C#实现远非完整。 这意味着一些基本功能是片状的(故障转移协议......好吧......在某些情况下失败,没有重新传递支持)而其他根本就不存在。 由于.NET似乎对项目来说并不是那么重要,因此开发速度相当慢,并且似乎没有任何发布计划。 Trunk经常被破坏

Storm 和JStorm

早过忘川 提交于 2019-12-25 22:49:30
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> 关于流处理框架,在先前的文章汇总已经介绍过 Strom ,今天学习的是来自阿里的的流处理框架JStorm。简单的概述Storm就是:JStorm 比Storm更稳定,更强大,更快,Storm上跑的程序,一行代码不变可以运行在JStorm上。直白的将JStorm是阿里巴巴的团队基于Storm的二次开发产物,相当于他们的Tengine是基于Ngix开发的一样。 阿里拥有自己的实时计算引擎 类似于hadoop 中的MR 开源storm响应太慢 开源社区的速度完全跟不上Ali的需求 降低未来运维成本 提供更多技术支持,加快内部业务响应速度 现有Storm无法满足一些需求 现有storm调度太简单粗暴,无法定制化 Storm 任务分配不平衡 RPC OOM一直没有解决 监控太简单 对ZK 访问频繁 JStorm 相比Storm更稳定 Nimbus 实现HA:当一台nimbus挂了,自动热切到备份nimbus 原生Storm RPC:Zeromq 使用堆外内存,导致OS 内存不够,Netty 导致OOM;JStorm底层RPC 采用netty + disruptor保证发送速度和接受速度是匹配的 新上线的任务不会冲击老的任务:新调度从cpu,memory,disk,net 四个角度对任务进行分配,已经分配好的新任务

ZeroMQ : getting Exception in thread “Timer-0” org.zeromq.ZMQException: Operation cannot be accomplished in current state(0x9523dfb) on retry

偶尔善良 提交于 2019-12-25 11:56:14
问题 i have this senario : client that try to send to server , but the server is offline . the socket.send(request, 0); in inside java Timer thread : this is the thread run() the ZMQ.Socket m_socket is initiates outside the thread public void run() { m_socket.send(request, 0); byte[] reply = m_socket.recv(0); //get seperator byte[] empty1 = m_socket.recv(0); //get secound frame byte[] byteFileStruct = m_socket.recv(0); if(null!=reply) // this is indication that the server is offline , is there

ZeroMQ - How to get rid of setTimeout in zeromq zmq implementation of Publishing messages?

大城市里の小女人 提交于 2019-12-25 08:43:08
问题 For example in publishing any messages we are using setTimeout() I tried to remove the timeout, but it doesn't publish any message. setTimeout(function () { var t = pub.send(mes + ' ' + stringObject, 0); }, 1000); I am using NodeJS ZMQ npm module. Is there any other approach to PUB / SUB pattern without adding setTimeout() function? Thanks 回答1: I highly recommend you read the guide, it answers this question along with many others. The reason you need to add the setTimeout() is because the PUB

another reliable way to do PULL-PUSH sync in ZeroMQ

烂漫一生 提交于 2019-12-25 05:20:13
问题 If you're using PUSH sockets, you'll find that the first PULL socket to connect will grab an unfair share of messages. The accurate rotation of messages only happens when all PULL sockets are successfully connected, which can take some milliseconds. As an alternative to PUSH/PULL, for lower data rates, consider using ROUTER/DEALER and the load balancing pattern. So one way to do sync in PUSH/PULL is using the load balancing pattern. For this specific case below, I wonder whether there is

Can ZMQ publish message to specific client by pub-sub socket?

六眼飞鱼酱① 提交于 2019-12-25 04:43:12
问题 I am using pub/Sub Socket and currently the server subscribe byte[0] (all topics) while client subscribe byte[16] - a specific header as topic However, I cannot stop client to subscribe byte[0] which can receive all other messages. My application is a like a app game which has one single server using ZMQ as connection and many clients have a ZMQ sockets to talk with server. What pattern or socket I should use in this case? Thanks 回答1: " ... cannot stop client to subscribe byte[0] which can

Can ZMQ publish message to specific client by pub-sub socket?

Deadly 提交于 2019-12-25 04:43:04
问题 I am using pub/Sub Socket and currently the server subscribe byte[0] (all topics) while client subscribe byte[16] - a specific header as topic However, I cannot stop client to subscribe byte[0] which can receive all other messages. My application is a like a app game which has one single server using ZMQ as connection and many clients have a ZMQ sockets to talk with server. What pattern or socket I should use in this case? Thanks 回答1: " ... cannot stop client to subscribe byte[0] which can

ZeroMQ + Django & uwsgi issues

风流意气都作罢 提交于 2019-12-25 02:53:47
问题 Using django, we need to send a message to another, separate python program. Zeromq seems to be lightweight and should fit the bill for this. However, trying to get it to work and it always ends up with a ZeroMQ: Bad Address error, when setting the socket to zmq.PUSH (or anything else). This is the traceback: Exception Type: ZMQError Exception Value: Bad address ... ... sock = context.socket(zmq.PUSH) /usr/local/lib/python2.7/dist-packages/zmq/sugar/context.py in socket s = self._socket_class

How can I limit total concurrent subscriber connections to a ZeroMQ publisher endpoint?

大城市里の小女人 提交于 2019-12-25 02:38:22
问题 When building a pub-sub service using ZeroMQ on a Linux system, is there any way to enforce concurrent subscriber limits? For example, I might want to create a ZeroMQ publisher service on a resource-limited system, and want to prevent overloading the system by setting a limit of, say, 100 concurrent connections to the tcp publisher endpoint. After that limit is reached, all subsequent connection attempts from ZeroMQ subscribers would fail. I understand ZeroMQ doesn't provide notifications

I get error #include <czmq.h> missing when running program

限于喜欢 提交于 2019-12-25 02:26:40
问题 I am trying from past 4 days to get Zeromq working on my Windows machine but nothings seems to go my way. I followed given steps and solved few dependcy issues. I have build libzmq,czmq,libsodium successfully. I used cmake 3.12 to configure and VS2015 SDK 8.1 to build solution. I was able to run czmq_selftest.exe however it failed for few things and thats different issue. But when I try to run basic program myapp.c #include <czmq.h> int main (void) { zsock_t *publisher = zsock_new (ZMQ_PUB);