qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Connor Poske <connor.po...@onrampwireless.com>
Subject RE: C++ client library Send() timeout
Date Thu, 14 Mar 2013 17:15:23 GMT
Thanks Gordon, I created QPID-4648

https://issues.apache.org/jira/browse/QPID-4648

I didn't see how to assign it to someone, maybe I don't have those privileges? 


________________________________________
From: Gordon Sim [gsim@redhat.com]
Sent: Thursday, March 14, 2013 2:29 AM
To: users@qpid.apache.org
Subject: Re: C++ client library Send() timeout

On 03/13/2013 04:55 PM, Connor Poske wrote:
> Thanks Gordon.
>
> We do use the getAvailable() function. The problem is this solution
> is only useful if you have exclusive access to the Sender. If thread
> B pushes a message to the Sender in between Thread A's call to
> getAvailble() and Send(), thread A is now blocked indefinitely,
> assuming there was only 1 slot available on the Sender initially.
>
> A potential work around is essentially a wrapper to Sender that
> provides an exclusive lock to the caller on the underlying Sender,
> and implements a timeout by checking getAvailable() until either
> timeout occurs or there is available space.

Senders are pretty cheap (though there is a roundtrip or two on setup),
so another workaround is to create a distinct Sender object for each
thread. As far as the transfers on the wire go, for 0-10 at least there
will be little difference.

> I would still request the timeout feature be added if I had such
> powers :)

The request doesn't require much in the way of power :) By all means
create a JIRA - assign to me for now so it doesn't get 'lost' and I'll
do my best to get to it, though I can't make any promises regarding
timing yet.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org


Mime
View raw message