Fix for file server logging inconsistent, updates to Alfresco debug logging interface used by the file server code. ALF-4672.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@22875 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Gary Spencer
2010-10-05 10:35:24 +00:00
parent 40e6c1e1d9
commit eb2e61a3f6
2 changed files with 36 additions and 1 deletions

View File

@@ -77,6 +77,40 @@ public class FileServerDebugInterface extends DebugInterfaceBase {
}
}
/**
* Output an exception
*
* @param ex Throwable
* @param level int
*/
public void debugPrintln( Throwable ex, int level) {
// Check if the logging level is enabled
if ( level <= getLogLevel()) {
// Output the exception
switch ( level) {
case Debug.Debug:
logger.debug( ex, ex);
break;
case Debug.Info:
logger.info( ex, ex);
break;
case Debug.Warn:
logger.warn( ex, ex);
break;
case Debug.Fatal:
logger.fatal( ex, ex);
break;
case Debug.Error:
logger.error( ex, ex);
break;
}
}
}
/**
* Output to the logger at the appropriate log level
*