activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <james.strac...@gmail.com>
Subject Re: [camel] Service Interface
Date Tue, 15 May 2007 06:19:45 GMT
On 5/14/07, Jeff Gunther <jeff.gunther@intalgent.com> wrote:
> I'm developing a component/endpoint that implements a FTP server.

Great!

> When the user uploads a file to the server, the endpoint will deposit
> the file into a queue. Currently, the Endpoint implements the Service
> interface. I've noticed that the "stop" method is not being called
> when the CamelContext is stopped.
>
> Is this a bug or am I missing something?

It sounds like a bug. BTW I made a slight change over the weekend so
that endpoints don't automatically start the producer/consumer inside
the create[Producer|Consumer]() methods, but rather the caller does
that (as I was having issues of multiple starts sometimes).

One complication is that an endpoint can be a singleton (in the spring
singleton sense), so that its created and then closed by the
CamelContext when its closed - or if its not a singleton, its
currently up to the caller to close it when its completed.

Maybe its a bit too easy to create non-singleton endpoints which then
don't get closed? We might wanna tighten up the lifecycle stuff a
little more maybe

-- 
James
-------
http://macstrac.blogspot.com/

Mime
View raw message