Re: [zeromq-dev] Lost message with PUSH/PULL
I think it might be the ZeroMQ behavior (which is probably a bug), once the connection is open ZeroMQ start to queue messages for the connection, even if handshake is not yet completed, so when you do telnet the message is not discarded but queue for the telnet connection. I think only PUSH is affected by this behavior, also fixing it might be hard, it also might be security issue, right now PUSH socket type is not safe for internet use because of this. If you can I suggest you reverse the bind/connection so PUSH will connect and PULL will bind. If not an option try to use ROUTER instead and have some kind of handshake. Nice catch, I still want to make sure that is really what happen and see if it possible to fix this easily.. On Thu, Jun 30, 2016 at 11:32 AM, 王运来wrote: > Hi every guys: >I got a problem which ZMQ will lost some messages with PUSH/PULL > ZMQ socket. >The scene like this: >A: PUSH socket, bind address "tcp://*.1209" >B: PULL socket, connect to "tcp://localhost:1209" > >Run the command "telnet localhost 1209" while A sending message to > B. > >The result is B will miss messages even if I set the option > of ZMQ_IMMEDIATE to 1 like this: >int immediate = 1; >zmq_setsockopt(pSock, ZMQ_IMMEDIATE, , sizeof(immediate)); > > Is it right in this scene or is it should be? > > > > > ___ > zeromq-dev mailing list > zeromq-dev@lists.zeromq.org > http://lists.zeromq.org/mailman/listinfo/zeromq-dev > ___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev
Re: [zeromq-dev] Lost message with PUSH/PULL
The latest API documentation does suggest that messages are NOT discarded. It would probably help everybody if you could provide the code (or at least recreate your problem with a simpler example). Creating a simple example might even lead you to discover what is going wrong. So it is definitely well worth the effort! On 30 June 2016 at 10:32, 王运来wrote: > Hi every guys: >I got a problem which ZMQ will lost some messages with PUSH/PULL > ZMQ socket. >The scene like this: >A: PUSH socket, bind address "tcp://*.1209" >B: PULL socket, connect to "tcp://localhost:1209" > >Run the command "telnet localhost 1209" while A sending message to > B. > >The result is B will miss messages even if I set the option > of ZMQ_IMMEDIATE to 1 like this: >int immediate = 1; >zmq_setsockopt(pSock, ZMQ_IMMEDIATE, , sizeof(immediate)); > > Is it right in this scene or is it should be? > > > > > ___ > zeromq-dev mailing list > zeromq-dev@lists.zeromq.org > http://lists.zeromq.org/mailman/listinfo/zeromq-dev > ___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev
Re: [zeromq-dev] Erlang implementation of ZMTP 3.1
Hi Andriy, Glad to see a full BEAM implementation. I've been working on something similar in Elixir ( https://github.com/SmartCasual/elixir-zeromq) but since you've gotten further in Erlang I'll take a look at contributing Curve support to yours instead, since all I really wanted was native BEAM instead of a binding to the C library given the dangers and/or inefficiencies of doing so. I'll have to look more closely into the licensing you've gone for to see whether it's compatible with my needs. Small note, but what you've got there is an implementation not a binding (which is a good thing). It would be a binding if it used e.g. the C library to do the work. Regards, Elliot On 28 June 2016 at 18:09, Andriy Drozdyukwrote: > At Pieter's suggestion, I am putting this here: > https://github.com/chovencorp/erlangzmq > > Native erlang 18 implementation of ZMTP 3.1 (including resource property), > but without any security. > > Hopefully it will be useful to people. I know I'll use it myself - since > all (native) erlang bindings are out of date. > > This is a six month young project, so this is NOT performance or > otherwise tested at all, and I would appreciate any feedback (just take a > second to file an issue). > > Thank you, > --Andriy Drozdyuk > > ___ > zeromq-dev mailing list > zeromq-dev@lists.zeromq.org > http://lists.zeromq.org/mailman/listinfo/zeromq-dev > ___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev
[zeromq-dev] Lost message with PUSH/PULL
Hi every guys: I got a problem which ZMQ will lost some messages with PUSH/PULL ZMQ socket. The scene like this: A: PUSH socket, bind address "tcp://*.1209" B: PULL socket, connect to "tcp://localhost:1209" Run the command "telnet localhost 1209" while A sending message to B. The result is B will miss messages even if I set the option of ZMQ_IMMEDIATE to 1 like this: int immediate = 1; zmq_setsockopt(pSock, ZMQ_IMMEDIATE, , sizeof(immediate)); Is it right in this scene or is it should be?___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev
Re: [zeromq-dev] Erlang implementation of ZMTP 3.1
In terms of getting patches back to the project, any share-alike license will work. In terms of adoption, xGPL irritates some people. So MPLv2 is a good compromise, and has worked well on the projects where we use it. So my strong recommendation for long term success is: - read http://zeromq.org/docs:organization - use MPLv2 and the C4 process - bring the project into the ZeroMQ organization on github - offer commercial support for clients that want it - read https://hintjens.gitbooks.io/social-architecture/content/ - learn to merge patches rapidly and with optimism :-) People won't (in our experience) make dark forks when you welcome their contributions. -Pieter On Wed, Jun 29, 2016 at 11:05 AM, Alex Blighwrote: > > On 29 Jun 2016, at 01:21, Andriy Drozdyuk wrote: > >> Interesting. I'm not married to AGPL, just don't want companies hogging any >> patches they made. > > I'm not an Erlang user, but if I needed bindings for a language and > I saw an AGPL licence, I'd write my own bindings and release them > with a BSD licence - I'd do that whether I was writing something > open source or commercial. LGPL might fly if all you're worried > about is ensuring patches to the project get recycled. > > Alex > >> >> On Tue, 28 Jun 2016 at 16:28 Pieter Hintjens wrote: >> This is really cool. >> >> The license choice will IMO hinder community growth around the project >> so I'd advise to you have a backup plan to switch to MPLv2 if the >> commercial uptake isn't sufficient. >> >> On Tue, Jun 28, 2016 at 7:09 PM, Andriy Drozdyuk wrote: >> > At Pieter's suggestion, I am putting this here: >> > https://github.com/chovencorp/erlangzmq >> > >> > Native erlang 18 implementation of ZMTP 3.1 (including resource property), >> > but without any security. >> > >> > Hopefully it will be useful to people. I know I'll use it myself - since >> > all >> > (native) erlang bindings are out of date. >> > >> > This is a six month young project, so this is NOT performance or otherwise >> > tested at all, and I would appreciate any feedback (just take a second to >> > file an issue). >> > >> > Thank you, >> > --Andriy Drozdyuk >> > >> > ___ >> > zeromq-dev mailing list >> > zeromq-dev@lists.zeromq.org >> > http://lists.zeromq.org/mailman/listinfo/zeromq-dev >> ___ >> zeromq-dev mailing list >> zeromq-dev@lists.zeromq.org >> http://lists.zeromq.org/mailman/listinfo/zeromq-dev >> ___ >> zeromq-dev mailing list >> zeromq-dev@lists.zeromq.org >> http://lists.zeromq.org/mailman/listinfo/zeromq-dev > > -- > Alex Bligh > > > > > ___ > zeromq-dev mailing list > zeromq-dev@lists.zeromq.org > http://lists.zeromq.org/mailman/listinfo/zeromq-dev ___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev