Skip to main content
Version: 8.2505.x.x RR

Logging configuration

Logging layout patterns

The pattern of each individual line logged by log4j can be customized in the layout element of an appender. See the following example:

Log Layout Appender Example
    RollingFile:
- name: SERVER
fileName: "log/nevislogrend.log"
filePattern: "log/nevislogrend.log.%i"
PatternLayout:
pattern: "%d{ISO8601} %-5.5p [%t] [%40.40c:%-4.5L] %X{indent}%m%n"
Policies:
SizeBasedTriggeringPolicy:
size: 10MB
DefaultRollOverStrategy:
max: 9

The above example will prefix log lines with the following, and in that order:

  • a date/time timestamp (%d),
  • the thread name (%t),
  • the conversation ID (%X{conversationId}),
  • the trace group (%c)
  • the priority of the trace message (%p).

It will also indent traces (%X{indent}).

Important trace groups

The following list shows the most important general trace groups, in combination with relevant debugging use cases:

  • Full trace analysis (debugging in test environment only)

      Root:
    level: WARN
    AppenderRef:
    ref: SERVER
  • General debugging

        - name: ch.nevis.logrend
    level: INFO
  • General debugging translation / GuiDescriptor problems

        - name: ch.nevis.logrend.beans.LoginBean
    level: DEBUG
  • Low level debugging

          - name: org.eclipse.jetty
    level: DEBUG
info

For all logging groups and their description, see the log4j configuration of your instance. If you need more examples, check the default configuration template here: /opt/nevislogrend/template/conf/logging.yml