#######################################################################
#                                                                     #
# Info                                                                #
#                                                                     #
#######################################################################

#----------------------------------------------------------------------
# Configure Log4J using system properties and/or a properties file:
#----------------------------------------------------------------------

# - log4j.configuration=log4j.properties

# Use this system property to specify the name of a Log4J configuration file.
# If not specified, the default configuration file is log4j.properties.

# - log4j.rootCategory=priority [, appender]

# Set the default (root) logger priority.

# - log4j.logger.logger.name=priority

# Set the priority for the named logger and all loggers hierarchically
# lower than, or below, the named logger. 'logger.name' corresponds to
# the parameter of LogFactory.getLog('logger.name'), used to create the
# logger instance. Priorities are: DEBUG, INFO, WARN, ERROR, or FATAL.
# Log4J understands hierarchical names, enabling control by package or
# high-level qualifiers: log4j.logger.org.apache.component=DEBUG will
# enable debug messages for all classes in both org.apache.component
# and org.apache.component.sub. Likewise, setting log4j.logger.org.apache.component=DEBUG
# will enable debug message for all 'component' classes, but not for
# other Jakarta projects.

# - log4j.appender.appender.threshold=priority

# Log4J appenders correspond to different output devices: console, files,
# sockets, and others. If appender's threshold is less than or equal to the
# message priority then the message is written by that appender. This allows
# different levels of detail to be appear at different log destinations.
# For example: one can capture DEBUG (and higher) level information in a logfile,
# while limiting console output to INFO (and higher).

#----------------------------------------------------------------------
# Message Priorities/Levels
#----------------------------------------------------------------------

# FATAL - Severe errors that cause premature termination. Expect these to
#         be immediately visible on a status console.
# ERROR - Other runtime errors or unexpected conditions. Expect these to
#         be immediately visible on a status console.
# WARN  - Use of deprecated APIs, poor use of API, 'almost' errors, other
#         runtime situations that are undesirable or unexpected, but not
#         necessarily "wrong". Expect these to be immediately visible on
#         a status console.
# INFO  - Interesting runtime events (startup/shutdown). Expect these to
#         be immediately visible on a console, so be conservative and keep
#         to a minimum.
# DEBUG - Detailed information on the flow through the system. Expect these
#         to be written to logs only.
# TRACE - More detailed information. Expect these to be written to logs only.

#######################################################################
#                                                                     #
# Basic configuration                                                 #
#                                                                     #
#######################################################################

# This is the configuring for logging displayed in the Application Server
#log4j.rootCategory=INFO, stdout

# Replace the line above if you want to put a log file into the directory
# you start Tomcat from
log4j.rootCategory=INFO, stdout, applicationLog

#----------------------------------------------------------------------
# STDOUT LOGGING
#----------------------------------------------------------------------

log4j.appender.stdout.threshold=WARN
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
# Pattern to output the caller's file name and line number.
log4j.appender.stdout.layout.ConversionPattern=%d{dd-MMM-yyyy HH.mm.ss} [Appalti]|%-5p|%m%n

#----------------------------------------------------------------------
# FILE LOGGING
#----------------------------------------------------------------------

log4j.appender.applicationLog.threshold=INFO
log4j.appender.applicationLog=org.apache.log4j.DailyRollingFileAppender
# You can change this to be an absolute path or even an environment variable
# If you're using an environment variable, you will have to set JAVA_OPTS
# to contain this variables - for example in the catalina.sh or catalina.bat
# file
log4j.appender.applicationLog.File=${catalina.home}/logs/Appalti.log
log4j.appender.applicationLog.DatePattern='.'yyyy-MM-dd
log4j.appender.applicationLog.layout=org.apache.log4j.PatternLayout
log4j.appender.applicationLog.layout.ConversionPattern=<%-5p> [%d] [%t] Classe: %c - Metodo: %M%n        Messaggio=%m%n%n

#######################################################################
#                                                                     #
# Logging configurations                                              #
#                                                                     #
#######################################################################

#----------------------------------------------------------------------
# APPLICATION
#----------------------------------------------------------------------

log4j.logger.it.eldasoft=ALL
log4j.logger.it.eldasoft.gene.commons.web.spring.DataSourceTransactionManagerBase=WARN

#----------------------------------------------------------------------
# SQLMAP
#----------------------------------------------------------------------

log4j.logger.java.sql.Connection=DEBUG
log4j.logger.java.sql.Statement=DEBUG
log4j.logger.java.sql.PreparedStatement=DEBUG
log4j.logger.java.sql.ResultSet=DEBUG

#----------------------------------------------------------------------
# CONTROL LOGGING FOR OTHER OPEN SOURCE PACKAGES
#----------------------------------------------------------------------

log4j.logger.org.apache.commons=ERROR
log4j.logger.org.apache.struts=WARN
log4j.logger.org.displaytag=ERROR
log4j.logger.org.springframework=WARN
log4j.logger.com.ibatis.db=WARN
log4j.logger.org.apache.velocity=FATAL