Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents
outlinh1. true
outlinh1. true
1printablefalse
2stylh1. none
3indent20px

Since version v1.5.3100-beta of the JobScheduler engine Engine it is possible to configure a logging api API of your choice to handle the log messages from JobScheduler (assumed the logging api API is supported by slf4j). Using this feature you have a wide range of possibilities to handle your logs, e.g. filtering, mailing, eventing etc.

Please look at How_to_configure_JobScheduler_logging for  for more information.

If you get find in the output of JobScheduler the lines

Code Block

 log4j:WARN No appenders could be found for logger (com.sos.scheduler.engine.kernel.plugin.PluginConfiguration).
 log4j:WARN Please initialize the log4j system properly.
 log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.

after you 've have started or stopped the JobScheduler then the JobScheduler logging uses log4j but log4j doesn't found did not find a configuration file.

The JobScheduler Starting from release 1.5.3253 is JobScheduler is shipped with an active log4j logging because as a slf4j-log4j12-x.jar is added to the java class path.

Code Block

 [java]
 class_path = $\{SCHEDULER_HOME\}/lib/*.jar;$\{SCHEDULER_HOME\}/lib/hibernate/*.jar;$\{SCHEDULER_HOME\}/lib/jetty_ext/*.jar;<span style="color:red">$\${SCHEDULER_HOME\}/lib/log/log4j/*.jar</span>jar

but without a log4j configuration file.

In this case please create a small default log4j configuration file ./lib/log4j.properties with the following content:

Code Block

 log4j.rootLogger=info, stdout
 log4j.appender.stdout=org.apache.log4j.ConsoleAppender
 log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
 log4j.appender.stdout.layout.ConversionPattern=%5p [%t] (%F:%L) - %m%n

and edit the ./config/factory.ini file with

Code Block

 [java]
 class_path = $\{SCHEDULER_HOME\}/lib/*.jar;$\{SCHEDULER_HOME\}/lib/hibernate/*.jar;$\{SCHEDULER_HOME\}/lib/jetty_ext/*.jar;$\{SCHEDULER_HOME\}/lib/log/log4j/*.jar
 <span style="color:red">optionsoptions    = -Dlog4j.configuration="file:///$\{SCHEDULER_HOME\}/lib/log4j.properties"</span>

so that log4j finds the configuration file.