[rabbitmq-discuss] How to configure timeout for rabbit client
Matthias Radestock
matthias at rabbitmq.com
Thu Jul 22 11:56:40 BST 2010
On 22/07/10 11:47, Emile Joubert wrote:
>> The java client does not currently support setting a socket timeout
> [...]
>
> Actually this is possible - com.rabbitmq.client.ConnectionFactory has a
> configureSocket() method that allows you to configure the timeout value
> of the socket.
Indeed. By overriding that method
(http://www.rabbitmq.com/releases/rabbitmq-java-client/v1.8.1/rabbitmq-java-client-javadoc-1.8.1/com/rabbitmq/client/ConnectionFactory.html#configureSocket%28java.net.Socket%29)
one gets full control over configuring the socket - not just for setting
timeouts, but also configuring buffer sizes, disabling nagle, etc.
Regards,
Matthias.
More information about the rabbitmq-discuss
mailing list