wrapper.logfile.rollmode

Compatibility :3.2.0
Editions :Professional EditionStandard EditionCommunity Edition
Platforms :WindowsMac OSXLinuxIBM AIXFreeBSDHP-UXSolarisIBM z/Linux

This property controls the roll mode of the log file. See the wrapper.logfile property for an explanation of how to name the log file.

The default value is SIZE.

Example:
wrapper.logfile.rollmode=SIZE

Starting from version 3.5.37, it is possible to roll the log file by date in combination with any of the modes listed below. This can be done by including the "YYYYMMDD" token in the value of wrapper.logfile.

When rolling by date, each log entry is logged to a file with a name containing a date corresponding to its timestamp. Whenever the date changes, a new log file will be start to be logged. This has the benefit of grouping all log entries for a given day in a specific file. A file will not be created on days which do not have any log output.

Possible mode values include:

  • NONE :

    In this mode, the log file will not be rolled by the Wrapper unless wrapper.logfile contains the "YYYYMMDD" token.

    In general, it is better to roll the log file, otherwise it could grow in size indefinitely and possibly eat up all available disc space should an application produce very large quantities of output.

    There are cases, however, where a user would want to disable log rolling by the Wrapper. An example is where an external log rolling tool is being used.

  • DATE (Alias of NONE since version 3.5.37):

    Prior to version 3.5.37, this value was used to roll the log file by date.

  • SIZE :

    In this mode, the log file will be rolled whenever its size exceeds the value defined by the wrapper.logfile.maxsize property.

  • WRAPPER :

    In this mode, the log file will be rolled when the Wrapper is first launched. This rolling will happen immediately after the configuration file has been loaded. For this reason, any configuration problems will be logged to the file prior to it being rolled. In this WRAPPER mode, the log files will not have a maximum size and will continue to grow until the Wrapper is restarted.

  • JVM :

    In this mode, the log file will be rolled on Wrapper startup as with the WRAPPER mode. But it will also be rolled just before any restarted JVMs are launched. In this JVM mode, the log files will not have a maximum size and will continue to grow until the Wrapper or a JVM is restarted.

  • SIZE_OR_WRAPPER :

    This mode combines the SIZE and WRAPPER modes. The log file will be rolled on Wrapper startup or whenever the log file exceeds the configured maximum size.

  • SIZE_OR_JVM :

    This mode combines the SIZE and JVM modes. The log file will be rolled on Wrapper startup, JVM restart, or whenever the log file exceeds the configured maximum size.

Reference: logfile