Package org.apache.synapse.transport.vfs
Class VFSTransportErrorHandler
- java.lang.Object
-
- org.apache.synapse.transport.vfs.VFSTransportErrorHandler
-
public class VFSTransportErrorHandler extends Object
This class is used to handle errors in VFS transportWe have not modified the original implementation, but we have included the error handling scenarios from
VFSTransportListener
,VFSTransportSender
andPollTableEntry
in this class.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
VFSTransportErrorHandler.LogType
This enum is used to define the log type
-
Constructor Summary
Constructors Constructor Description VFSTransportErrorHandler()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
constructLogMessage(String message, String configName)
This method is used to construct the log messagestatic void
handleException(org.apache.commons.logging.Log log, String message)
This method is used to handle exceptions.static void
handleException(org.apache.commons.logging.Log log, String message, Exception e)
This method is used to handle exceptions.static void
handleException(org.apache.commons.logging.Log log, String message, String configName)
This method is used to handle exceptions.static void
handleException(org.apache.commons.logging.Log log, String message, String configName, Exception e)
This method is used to handle exceptions.static void
logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message)
This method is used to log exceptions without exceptionstatic void
logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message, Exception e)
This method is used to log exceptions with exceptionstatic void
logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message, String configName)
This method is used to log exceptions without exceptionstatic void
logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message, String configName, Exception e)
This method is used to log exceptions with exceptionstatic void
printStackTrace(Exception e)
This method is used to handle print the stack tracestatic void
throwException(RuntimeException e)
This method is used to throw a Runtime exception
-
-
-
Method Detail
-
logException
public static void logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message, Exception e)
This method is used to log exceptions with exception- Parameters:
log
- Logtype
-VFSTransportErrorHandler.LogType
message
- String message to be loggede
- Exception
-
logException
public static void logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message, String configName, Exception e)
This method is used to log exceptions with exception- Parameters:
log
- Logtype
-VFSTransportErrorHandler.LogType
message
- String message to be loggedconfigName
- String name of the configuratione
- Exception
-
logException
public static void logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message)
This method is used to log exceptions without exception- Parameters:
log
- Logtype
-VFSTransportErrorHandler.LogType
message
- String message to be logged
-
logException
public static void logException(org.apache.commons.logging.Log log, VFSTransportErrorHandler.LogType type, String message, String configName)
This method is used to log exceptions without exception- Parameters:
log
- Logtype
-VFSTransportErrorHandler.LogType
message
- String message to be loggedconfigName
- String name of the configuration
-
handleException
public static void handleException(org.apache.commons.logging.Log log, String message, Exception e) throws org.apache.axis2.AxisFault
This method is used to handle exceptions. Log error message and throws an AxisFault with the exception- Parameters:
log
- Logmessage
- String message to be loggede
- Exception- Throws:
org.apache.axis2.AxisFault
-
handleException
public static void handleException(org.apache.commons.logging.Log log, String message, String configName, Exception e) throws org.apache.axis2.AxisFault
This method is used to handle exceptions. Log error message and throws an AxisFault with the exception- Parameters:
log
- Logmessage
- String message to be loggedconfigName
- String name of the configuratione
- Exception- Throws:
org.apache.axis2.AxisFault
-
handleException
public static void handleException(org.apache.commons.logging.Log log, String message) throws org.apache.axis2.AxisFault
This method is used to handle exceptions. Log error message and throws an AxisFault- Parameters:
log
- Logmessage
- String message to be logged- Throws:
org.apache.axis2.AxisFault
-
handleException
public static void handleException(org.apache.commons.logging.Log log, String message, String configName) throws org.apache.axis2.AxisFault
This method is used to handle exceptions. Log error message and throws an AxisFault- Parameters:
log
- Logmessage
- String message to be loggedconfigName
- String name of the configuration- Throws:
org.apache.axis2.AxisFault
-
printStackTrace
public static void printStackTrace(Exception e)
This method is used to handle print the stack trace- Parameters:
e
- InterruptedException
-
throwException
public static void throwException(RuntimeException e)
This method is used to throw a Runtime exception- Parameters:
e
- Exception
-
-