private void stop() { try { Bus.activeBuses.remove(uri); } catch(Exception e) { ErrorHandler.getInstance().handle(e); } }
/** * Returns the singleton instance of the system wide ErrorHandler * * @return */ public static ErrorHandler getInstance() { if(singleton == null) { synchronized(ErrorHandler.class) { if(singleton == null) { singleton = new ErrorHandler(); } } } return singleton; }
public void broadcastChannelEvent(ChannelEvent channelEvent) { if(this.channelListeners != null) { for(ChannelEventListener listener: this.channelListeners) { try { listener.channelUpdated(channelEvent); } catch(Exception e) { //so that if an error occurs on one listener, others don't suffer //listeners must be isolated of each other try{ErrorHandler.getInstance().handle(e);}catch(Exception ex){} } } } }
public void broadcastNetworkEvent(NetworkEvent networkEvent) { if(this.networkEventListeners != null) { for(NetworkEventListener listener: this.networkEventListeners) { try { listener.serverPush(networkEvent); } catch(Exception e) { //so that if an error occurs on one listener, others don't suffer //listeners must be isolated of each other try{ErrorHandler.getInstance().handle(e);}catch(Exception ex){} } } } } }
private void sendBusListenerEvent(Bus bus,BusMessage busMessage) { List<BusListener> busListeners = bus.getBusListeners(); if(busListeners == null) { return; } for(BusListener busListener: busListeners) { try { busListener.messageIncoming(busMessage); } catch(Exception e) { //so that if an error occurs on one listener, others don't suffer //listeners must be isolated of each other try{ErrorHandler.getInstance().handle(e);}catch(Exception ex){} } } } }
ErrorHandler.getInstance().handle(e);
ErrorHandler.getInstance().handle(e);
ErrorHandler.getInstance().handle(pe); session.setAttribute("tx-rollback", Boolean.TRUE); ErrorHandler.getInstance().handle(e); session.setAttribute("tx-rollback", Boolean.TRUE);
ErrorHandler.getInstance().handle(e); throw new SystemException(e.getMessage(), e);
ErrorHandler.getInstance().handle(e); throw new SystemException(e.getMessage(), e);
ErrorHandler.getInstance().handle(e);
ErrorHandler.getInstance().handle(e); throw new SystemException(e.getMessage(), e);
ErrorHandler.getInstance().handle(e); logger.error(this, e); session.setRollback(true);
ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe); catch(HornetQException hqe) ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe);
ErrorHandler.getInstance().handle(e); logger.error(this, e); session.setRollback(true); ErrorHandler.getInstance().handle(e); logger.error(this, e); session.setRollback(true); ErrorHandler.getInstance().handle(e); logger.error(this, e); session.setRollback(true);
ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe); catch(HornetQException hqe) ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe); catch(HornetQException hqe) ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe);
ErrorHandler.getInstance().handle(e); ErrorHandler.getInstance().handle(e);
ErrorHandler.getInstance().handle(e); throw new SystemException(e.getMessage(), e);
ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe); ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe); ErrorHandler.getInstance().handle(hqe); throw new SystemException(hqe.getMessage(),hqe);
ErrorHandler.getInstance().handle(e);