Re: [zeromq-dev] I'm losing messages doing 2 way heartbeat checks (MinRK)

2011-05-23 Thread Matthew Giedt
> Hi, > > I think you might be getting caught up with the fact that zmq FD > events are edge-triggered. When you have a handler registered for a > POLLIN event, it must handle *all* available incoming messages, > otherwise if you have multiple incoming messages ready at the same > time, you will o

[zeromq-dev] recv timeout?

2010-05-15 Thread Matthew Giedt
Hi Martin, I know this was discussed a while back and am just curious where your thinking is at in regards to a timeout parameter supplied to recv for [REQ / REP] RPC use cases where the reply is never going to happen... With thanks, -Matt ___ zeromq-de

Re: [zeromq-dev] Problems with 2.0.6 poll using C++ api

2010-03-19 Thread Matthew Giedt
Here's my OS: uname -a Linux ubuntu 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:05:01 UTC 2009 x86_64 GNU/Linux The following shows: 1. The application I'm running 2. The output of that application 3. My modifications to dispatcher.cpp and zmq.cpp Notice that both sockets have a thread_slot

Re: [zeromq-dev] Problems with 2.0.6 poll using C++ api

2010-03-18 Thread Matthew Giedt
I'm simply trying to get the simplest possible 'polling' example working. I have two local PUB sockets sending a message every second, on ports 5550, 5551. The recv printout just verifies that I'm able to receive messages, prior to then attempting to poll. I actually exported CXXFLAGS="-ggdb3" and

[zeromq-dev] Problems with 2.0.6 poll using C++ api

2010-03-18 Thread Matthew Giedt
Here's the application that I'm using to test: int main( int argc, char *argv[] ) { int signum = 0; zmq::message_t msg; zmq::socket_t* sock1; zmq::socket_t* sock2; zmq::context_t ctx ( 1, 1, 0 ); sock1 = new zmq::socket_t( ctx, ZMQ_SUB ); sock1->connect( "tcp://127.0.0

Re: [zeromq-dev] ZMQ 2.0.6 connect SUB socket error

2010-03-18 Thread Matthew Giedt
I'm not sure what the problem was on my machine but after fooling the network interface into thinking that eth0 was a static IP and restarting, the C_API is now happy to return 0 from getaddrinfo. Apologies for the run-around. Regards, -Matt On Wed, Mar 17, 2010 at 4:44 PM, Matthew Giedt

Re: [zeromq-dev] ZMQ 2.0.6 connect SUB socket error

2010-03-17 Thread Matthew Giedt
I traced the application to the point where it calls getaddrinfo which is failing on my linux machine. It's returning 1, with the error: Name or service not known I boiled down everything to: (copied straight from ip.cpp) int main( int argc, char *argv[] ) { addrinfo req; memset (&req, 0

Re: [zeromq-dev] ZMQ 2.0.6 connect SUB socket error

2010-03-17 Thread Matthew Giedt
smitted, 1 received, 0% packet loss, time 0ms rtt min/avg/max/mdev = 0.048/0.048/0.048/0.000 ms mgi...@ubuntu:~/bdsquant/trunk/source/mktdata_engine/cpp$ On Wed, Mar 17, 2010 at 11:27 AM, Martin Sustrik wrote: > Hello, > > > Matthew Giedt wrote: > >> Hello -- >> &

[zeromq-dev] ZMQ 2.0.6 connect SUB socket error

2010-03-17 Thread Matthew Giedt
Hello -- I just upgraded from 2.0b2 to 2.0.6 -- (downloaded, ./configure --> make --> make install, verified new libraries and include) When running the following program with: ./test tcp://lo:5551 tcp://localhost:5551 data.txt I get: publishing on: tcp://lo:5551 success. subscribing on: tcp: