Thank you for your further clarification.

> What we do when we send a request, as each request has a unique id
(the
> MessageId in our case) is that we are able to match the future a
client
> is waiting on as we have associated this future with the messageId in
a
> Map. If we get an exceptionCaugth(), we get the messageId for the
> message that generated this exception, and find the associated future,
> that we now cancel.

Another issue that I face - which I have just noticed - is that I am not
using version 2 of Mina. I have 1.1.7 and as such don't have a cancel()
method for my ConnectFuture object. Is there a way one can achieve the
same thing using my earlier version of Mina?

> If the exception is not associated with any messageId, then you should
> close the session, and reconnect it, because it's very likely that the
> exception is due to some big problem.

I can close the session easily enough in exceptionCaught(), but am not
sure how to reconnect it. Can you explain how you achieve that, please?

With continual thanks,

Mark

Reply via email to