Hi,

We have got a use case where we need to mark a downloaded message as
"downloaded"
and right now our implementation logic is using camel to do essentially
this:


from("jetty:http://server/url";)
.... lots of logic
   .to("direct:fetch");

from("direct:fetch")
   .onCompletion()
        .beanRef("messageLogService", "messageFetched(${property.entry})")
   .end()
.beanRef("messageLogService", "fetchMessage(${property.entry})")
.convertBodyTo(InputStream.class);


We're streaming the message to the client and we really need to
be able to catch when the client disconnects and won't be able to
receive the complete message.
Then our exception handler should kick in and mark the message dirty again.

It works perfectly when client reads all content,
but sadly it still is marked "fetched" when client is forcefully
disconnected.

Is it possible to know when jetty client connection disconnects?
And have the entire exchange, and it's sub-routes, cancelled?

Reply via email to