xmlBlaster 2.2.0 API

org.xmlBlaster.engine
Class MsgErrorHandler

java.lang.Object
  extended by org.xmlBlaster.engine.MsgErrorHandler
All Implemented Interfaces:
I_MsgErrorHandler

public final class MsgErrorHandler
extends java.lang.Object
implements I_MsgErrorHandler

The default error recovery implementation for messages which are lost in time and universe.

Author:
xmlBlaster@marcelruff.info, michele@laghi.eu

Field Summary
private  ServerScope glob
           
private static java.util.logging.Logger log
           
private  long MAX_BYTES
           
private  SessionInfo sessionInfo
           
 
Constructor Summary
MsgErrorHandler(ServerScope glob, SessionInfo sessionInfo)
           
 
Method Summary
 void handleError(I_MsgErrorInfo msgErrorInfo)
          The final recovery, all informations necessary are transported in msgErrorInfo We expect three error types: ErrorCodeAction ErrorCode.USER* User errors are thrown from remote clients update() method, we handle only the bounced back messages.
 java.lang.String handleErrorSync(I_MsgErrorInfo msgErrorInfo)
          This should never happen on server side, so we just call handleError(I_MsgErrorInfo).
 void shutdown()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAX_BYTES

private final long MAX_BYTES
See Also:
Constant Field Values

glob

private final ServerScope glob

log

private static java.util.logging.Logger log

sessionInfo

private SessionInfo sessionInfo
Constructor Detail

MsgErrorHandler

public MsgErrorHandler(ServerScope glob,
                       SessionInfo sessionInfo)
Parameters:
sessionInfo - Can be null (e.g. for Subject errors)
Method Detail

handleError

public void handleError(I_MsgErrorInfo msgErrorInfo)
The final recovery, all informations necessary are transported in msgErrorInfo We expect three error types:
ErrorCodeAction
ErrorCode.USER* User errors are thrown from remote clients update() method, we handle only the bounced back messages. We take care to remove them from the queue
ErrorCode.COMMUNICATION* The connection went to state==DEAD, we recover all messages from the queue
Other exceptions from mime access plugin Those messages have not entered the queue yet, they have no impact on the dispatcher framework (no queue flushing etc.)
Other exceptions from dispatcher framework They are handled as internal problems, we do the same as with COMMUNICATION* exception

Specified by:
handleError in interface I_MsgErrorHandler

handleErrorSync

public java.lang.String handleErrorSync(I_MsgErrorInfo msgErrorInfo)
                                 throws XmlBlasterException
This should never happen on server side, so we just call handleError(I_MsgErrorInfo).

Specified by:
handleErrorSync in interface I_MsgErrorHandler
Returns:
null or a useful message return qos
Throws:
XmlBlasterException - is thrown if we are in sync mode and we have no COMMUNICATION problem, the client shall handle it himself

shutdown

public void shutdown()
Specified by:
shutdown in interface I_MsgErrorHandler

xmlBlaster 2.2.0 API

Copyright © 1999-2014 The xmlBlaster.org contributers.