IRC Log


Tuesday November 9, 2010

[Time] NameMessage
[03:03] Led_Zeppelin hello.
[03:03] Led_Zeppelin Is it possible to have a UDP socket with 0mq?
[03:14] gandhijee hey, what would the socket be to only send msgs to a server?
[03:14] gandhijee and i guess the server would have to open in rec only mode?
[08:49] mikko gandhijee: PUSH/PULL, PUB/SUB
[09:12] mrshpot hi
[09:13] mrshpot is it OK to pass sockets between threads in ZeroMQ 2.1.0-git?
[09:16] Guthur mrshpot: AFAIK sharing sockets between threads is not supported
[09:16] mrshpot thanks
[09:17] guido_g in 2.1.x you can move a socket from one thread to another
[09:17] Guthur oh, sorry my bad
[09:17] guido_g *shared* use of a socket is still not supported
[09:17] mrshpot I want to have two threads: one that is receiving, and another one that is sending
[09:18] mrshpot so I can't do that
[09:18] guido_g right
[09:18] mrshpot thank you :)
[09:18] guido_g stupid idea anyway, because ømq uses one io thread itself
[09:19] mikko mrshpot: what kind of situation would you use that design for?
[09:19] mikko one thread receiving and one sending
[09:19] mikko on same socket that is
[09:20] mrshpot there is a worker performing a two-step computation
[09:20] mrshpot and a "receive; calculate; send" pattern makes it stay idle for quite a time
[09:21] mrshpot it would be more efficient to have a request queue and a response queue
[09:21] mikko why don't you do recv/send in one thread and use inproc to hand work to worker threads?
[09:22] guido_g receive / calculate / send doesn't sound like the thread has not enough to do
[09:23] guido_g the sending is very fast, because it _simply_ pushes the data to the io thread internally
[09:23] guido_g so after sending thread would get the next message quite fast
[09:24] mrshpot I guess I'll go with single-threaded send/recv, then
[09:24] guido_g right
[09:25] guido_g allways *try* the simple things first
[09:25] mrshpot :-)
[10:13] Guthur sustrik, are you maintain the erlang binding?
[11:11] pieterh Guthur, the maintainer should be mentioned on the binding page
[11:11] pieterh Serge Aleynikov and Dhammika Pathirana, it says
[12:02] Guthur pieterh: Ah ok, cheers
[13:54] Guthur is ZFL at an early stage of development?
[13:54] Guthur It doesn't seem to be very well advertised
[13:57] Tester hey guys, I want to build a tcp server with 0mq, that would connect to non-0mq clients
[13:57] Tester is there any problem combining 0mq and non-0mq sockets?
[13:57] mikko Tester: would your clients speak 0mq wire protocol?
[13:57] Tester no
[13:58] Tester plain tcp
[13:58] mikko then they couldn't really talk with 0mq
[13:59] Tester I have control over hte server, not the clients... that's the problem
[13:59] mikko as zeromq has a wire protocol for frames
[13:59] Tester I see
[13:59] guido_g there is no problem in using os level sockets in parallel w/ ømq sockets
[14:00] guido_g you can even use them in the same event loop because ømq poll can handle normal (os level) sockets
[14:01] guido_g so your clients can connect via tcp using their protocol and you can use ømq sockets for inter-server communication
[14:03] Tester I see. My intention was to communicate directly to the clientes
[14:03] Tester thanks guys
[14:03] guido_g then the clients need to use ømq as well, as mikko said
[16:06] Steve-o so who has any experience with IOCP?
[16:10] mikko Steve-o: i am getting build errors (with ICC) when building zeromq2 --with-pgm
[16:10] Steve-o The only best practices I can find is setting SO_SNDBUF to 0 and queuing up multiple sends, but for receive you must not set SO_RCVBUF to zero and you only need one pending recv
[16:11] Steve-o mikko: ok, I think I sent a list of required changes to the list already?
[16:11] mikko Steve-o: i might've missed that
[16:11] mikko let me see
[16:11] Steve-o There's no Autoconf for PGM so it only has support for Linux & MinGW32
[16:12] Steve-o you want the changes listed in the intelc build environment here, http://code.google.com/p/openpgm/source/browse/trunk/openpgm/pgm/SConstruct.097.intelc
[16:13] mikko i think the build env itself works ok
[16:13] mikko i keep getting error on line for (unsigned i; ...
[16:14] mikko unsigned i = 0
[16:14] mikko i thought that is legal in C++ but not in C
[16:14] Steve-o legal for C99
[16:14] Steve-o hence you need -std=c99 flag
[16:16] Steve-o I think you only need to add the flags -std=c99 -D_XOPEN_SOURCE=600 -D_BSD_SOURCE -gcc-version=420
[16:16] Steve-o I'm off house hunting be back later.
[16:17] mikko -std=gnu99 at the moment
[16:17] mikko seems like icc barfs with -std=gnu99 but works with -std=c99
[18:29] Steve-o mikko: also of note is that icc yields worse performance than gcc for PGM, so ideally you build nodist-libpgm with gcc and the rest of zeromq with icc
[19:05] mikko steve, havent got so fine-grained daily builds yet
[19:06] mikko but think im gonna ahck at this at some point
[19:07] Steve-o I wish there were better solutions but some platforms I cannot reliably detect features programmatically.
[19:08] zomg mikko: out of curiosity, you using zmq with PHP or something else?
[21:16] Guthur clrzmq2 actually works on linux out of the box
[21:16] Guthur I'm well chuffed
[22:58] mcr19 what is the preferred site to upload sample code for reference on zeromq-dev?
[23:26] kisielk mcr19: probably github?