Script Logging Levels

Scripts use log messages to communicate with users. In EPM Workspace, logs are accessed through the Show Task Status list. On the desktop, in Interactive Reporting Studio, users view dds.log.

There are a number of defined logging levels. For example,

5-debug = many messages

0-Always = few messages

The levels are explained in Table 24.

Table 24. Logging Levels

Level

Description

Debug

Determines what is happening during script development or to track down problems

Warn

Warns of recoverable problems that require correcting

Error

Indicates the inability to correctly perform the requested processing

Fatal

Indicates the script cannot continue

Always

Messages that are always displayed

There are env methods available to log messages at each of these levels. For example, env.logInfo() or env.logDebug().

There is also a default logging level associated with the script execution. The env.log() method logs messages at that level. The default level is initially debug, but can be changed by using env.setLogLevel().

The env.logClassName() method provides information on the type of an object, because values returned by methods are a combination of JavaScript and Java objects.