-
1. Re: Errai Client Unsubscribe
cbrock Jun 3, 2010 2:26 PM (in response to s4smart)1 of 1 people found this helpfulUnfortunately, there is no specific way to detect when the app server is shut down or when a client is disconnected directly. We use a heartbeat system to detect when the connection has been broken, and unsubscribe events will be fired at the time the housekeeper reigns those dead connections in.
-
2. Re: Errai Client Unsubscribe
s4smart Jun 3, 2010 2:32 PM (in response to cbrock)Thanks for the reply . If its automatically detected , then is there a graceful way of not showing the error Dialog Box Window .
when my server goes down . if the client is connected to it
-
3. Re: Errai Client Unsubscribe
cbrock Jun 3, 2010 2:42 PM (in response to s4smart)Yes, you can. This needs to be better documented and the API will probably need to be cleaned up in the future. But you can change the LogAdapter which is responsible for showing that default error dialog:
ClientMessageBusImpl bus = (ClientMessageBusImpl) ErraiBus.get();
bus.setLogAdapter( new MyLogAdapterImpl() );
The LogAdapter interface is pretty self explainatory.
-
4. Re: Errai Client Unsubscribe
s4smart Jun 3, 2010 6:24 PM (in response to cbrock)Great . That was helpful and it worked.