IASLogger

org.eso.ias.logging.IASLogger
object IASLogger

IASLogger is the binding to the logging mechanism for the IAS.

The purpose of IASLogger is to have a centralized initialization of the logger for all IAS applications so that it will be possible to change the logging by changing this class but transparently to user applications.

The user shall get a logger with one of the factory methods.

Attributes

Since

Oct 2016

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
IASLogger.type

Members list

Value members

Concrete methods

def getLogger(name: String): Logger

Attributes

Returns

A logger with the given name

def getLogger(c: Class[_]): Logger
def printLoggerStatus(): Unit

Print the status of the logger in the stdout for debugging purposes

Print the status of the logger in the stdout for debugging purposes

logback configuration file can be tweaked to automatically print debug information even if there is no error by setting the debug attribute of the configuration tag to true

Attributes

def setLogLevel(pkg: String, level: Level): Unit

Set the log level of the package to the passed level/

Set the log level of the package to the passed level/

This code is dependent of logback because slf4j does not offer any API to set the log level.

Value parameters

level

the log level to set

pkg

the package to change the log level

Attributes

def setLogLevel(commandLineLevel: Option[Level], iasConfigLevel: Option[Level], toolLevel: Option[Level]): Option[Level]

Set the log level depending if it is passed in the command line, the IAS configuration or the configuration of the tool like the Supervisor)

Set the log level depending if it is passed in the command line, the IAS configuration or the configuration of the tool like the Supervisor)

If none of the level is defined, no log level is set.

The precedence is as follow: 1 command line 2 tool 3 IAS

Value parameters

commandLineLevel

the level read from the command line, if present

iasConfigLevel

the level read from the IAS configuration in the CDB, if present

toolLevel

the level read from the tool configuration in the CDB, if present

Attributes

Returns

the log level that has been set; undefined otherwise

def setLogLevel(commandLineLevel: Level, iasConfigLevel: Level, toolLevel: Level): Level

Set the log level depending if it is passed in the command line, the IAS configuration or the configuration of the tool like the Supervisor)

Set the log level depending if it is passed in the command line, the IAS configuration or the configuration of the tool like the Supervisor)

This is a helper method for java

Value parameters

commandLineLevel

the level read from the command line (can be null)

iasConfigLevel

the level read from the IAS configuration in the CDB (can be null)

toolLevel

the level read from the tool configuration in the CDB (can be null)

Attributes

Returns

the log level that has been set; null otherwise

def setRootLogLevel(level: Level): Unit

Set the log level of the root to the passed level/

Set the log level of the root to the passed level/

This code is dependent of logback because slf4j does not offer any API to set the log level.

Value parameters

level

the log level to set

Attributes