[rabbitmq-discuss] dotnet client background thread

joefitzgerald joeyfitz at gmail.com
Fri Dec 16 15:39:17 GMT 2011


I should also note that I am the maintainer of Spring AMQP for .NET
(and as a consequence, the RabbitMQ.Client NuGet package), and we're
closing in on a 1.0.0.0 M2 release. If you're OK living on the semi-
bleeding edge, there are two NuGet packages for Spring AMQP for .NET:

* https://nuget.org/packages/Spring.Messaging.Amqp
* https://nuget.org/packages/Spring.Messaging.Amqp.Rabbit

This should be considered _alpha_, but it's in use in production
environments at clients, and is stable in observed use. 1.0.0.0 will
be released in Q1 2012. Any help (this is an open source project) is
greatly appreciated. The Github repo is here: https://github.com/SpringSource/spring-net-amqp`

Needless to day, we implement IDisposable :) Your connections will be
shut down when the application exits.

Cheers,
Joe

On Dec 16, 8:30 am, joefitzgerald <joeyf... at gmail.com> wrote:
> It's even easier than that if you're using Spring.NET. Any object that
> implements IDisposable is disposed automatically by the Spring.NET
> container when the container is destroyed. The container is destroyed
> when the application shuts down, and I think they use the ProcessExit
> event to make that happen.
>
> Reference:http://www.springframework.net/doc-latest/reference/html/objects.html...
>
> Cheers,
> Joe
>
> On Dec 16, 7:53 am, Brian Lalor <bla... at bravo5.org> wrote:> On Dec 16, 2011, at 9:43 AM, Tony Garnock-Jones wrote:
>
> > > Stepping back from the immediate problem, the "real" solution is to have the JVM and .NET virtual machines grow up and behave like proper systems, complete with lifecycle events. Then, AMQP connections have a chance to clean up and disconnect on their own, without special action on the part of the programmer and without unduly delaying or preventing VM shutdown.
>
> > If you use Spring, you get events like these.  With Spring for Java, you can use the destroy-method attribute of the  <bean />  element to invoke a method when the context is shutting down.  I haven't used Spring with .Net, but I'd be surprised if there weren't a similar mechanism there.
>
> > _______________________________________________
> > rabbitmq-discuss mailing list
> > rabbitmq-disc... at lists.rabbitmq.comhttps://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-disc... at lists.rabbitmq.comhttps://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss


More information about the rabbitmq-discuss mailing list