5 Replies Latest reply on Jun 9, 2009 10:08 AM by slimamar

    How to Intercep a client close on the server side

    jay.howell

      JBM 1.4.0 sp3 CP04

      If I want a notification on the server side that a connection has been closed(either called close on the connection or closed due to network error), how do you get a server notification.

      I've tried to use the aspects, but the connection advised doesn't get called when the connection is shut down due to error.

      My last option is to do runtime weaving and use an aroundinvoke around handleConnectionException in the SimpleConnectionManager

      Since the flow calls close and closing on the and does not call the connectionAdvised, it seems like this is a bug. Shouldn't the connectionAdvised get called in the event of a client failure. I would think that on the server side methods for closing and close should be called for the connectionAdvised. It seems like a bug, but I can also see it the other way... The code fix for the bug would be to wrap the endpoint in the connectionAdvised and call that in the SimpleConnection in cleanupForSessionID instead of calling the endpoint directly.

      Jay:)