[rabbitmq-discuss] .Net Client locks trying to create a channel on a blocked connection
Francesco Mazzoli
francesco at rabbitmq.com
Fri Aug 24 12:00:52 BST 2012
At Fri, 24 Aug 2012 01:57:20 -0700 (PDT),
kzhen wrote:
> If the CreateModel timed out instead, or threw an exception if it couldn't
> establish a connection that would be the ideal situation. As it is I'm left
> with a thread just sitting there blocked, when I try to stop the windows
> service that this is running in it will just sit there...for a very long time
> because it can't clean this up. The channel would be used to publish new
> messages.
>
> My app is a REST service that is called to enqueue a message, but what is
> happening is that the http request will never get a response due to the
> channel being blocked...
>
> I would agree blocking makes sense, but having an overload which takes a
> timeout parameter would make my life a whole lot easier!
You can set up the timeout yourself, for example by spawning a thread that will
try to do some operation and terminating it if it doesn't complete after a
certain amount of time.
I don't maintain the C# client (and I don't know much about C# either) but
introducing support for such a thing in the library would be quite a big change
and I don't it's going to happen.
--
Francesco * Often in error, never in doubt
More information about the rabbitmq-discuss
mailing list