Interface PaxLoggingConstants


  • public interface PaxLoggingConstants

    Different constants used across Pax Logging.

    Constants names use the following prefixes:

    • LOGGING_CFG_ - for system or context property names
    • PID_CFG_ - for property names found in org.ops4j.pax.logging PID
    • SERVICE_PROPERTY_ - for names of OSGi service properties
    • Field Detail

      • LOGGING_CONFIGURATION_PID

        static final String LOGGING_CONFIGURATION_PID
        The Managed Service PID for logging configuration. Format is specific to chosen backend.
        See Also:
        Constant Field Values
      • LOGGING_LOGSERVICE_NAMES

        static final String[] LOGGING_LOGSERVICE_NAMES
        Each backend will register its service under these objectClass names.
      • LOGGING_CFG_SKIP_JUL

        static final String LOGGING_CFG_SKIP_JUL
        System or context (in that order) property to skip Java Util Logging bridge registration.
        See Also:
        Constant Field Values
      • LOGGING_CFG_SKIP_JUL_SYNCHRONIZED_FORMATTER

        static final String LOGGING_CFG_SKIP_JUL_SYNCHRONIZED_FORMATTER
        System or context (in that order) property to use single, synchronized SimpleFormatter in JdkHandler.publish(LogRecord) (which is the default) or new instance should be used for each event (to prevent deadlocks in special circumstances).
        See Also:
        Constant Field Values
      • LOGGING_CFG_FRAMEWORK_EVENTS_LOG_LEVEL

        static final String LOGGING_CFG_FRAMEWORK_EVENTS_LOG_LEVEL
        System or context (in that order) property setting the threshold for framework/bundle/service events. OSGi Compendium R7, 101.8 "Mapping of Events" defines levels for standard events and with this property we can filter out some of them.
        See Also:
        Constant Field Values
      • LOGGING_CFG_DEFAULT_LOG_LEVEL

        static final String LOGGING_CFG_DEFAULT_LOG_LEVEL
        System or context (in that order) property that specifies threshold for fallback logger used behind all facades, handled by pax-logging-api.
        See Also:
        Constant Field Values
      • LOGGING_CFG_USE_BUFFERING_FALLBACK_LOGGER

        static final String LOGGING_CFG_USE_BUFFERING_FALLBACK_LOGGER
        System or context (in that order) property that selects buffering fallback logger.
        See Also:
        Constant Field Values
      • LOGGING_CFG_USE_FILE_FALLBACK_LOGGER

        static final String LOGGING_CFG_USE_FILE_FALLBACK_LOGGER
        System or context (in that order) property that selects file-based fallback logger. The value should be writable filename. Turning on this logger will enable synchronization and register singleton stream used by all instances of FileServiceLog.
        See Also:
        Constant Field Values
      • LOGGING_CFG_TLS_LOGGING_MODE

        static final String LOGGING_CFG_TLS_LOGGING_MODE
        System property that specifies the TLS debug logging mode. The TLS records logging modes are:
        • no_logging - TLS messages are not logged
        • no_hex_dumps_logging - all messages except hex dumps are logged
        • debug_logging - all messages are logged
        See Also:
        Constant Field Values
      • PID_CFG_LOG_READER_SIZE_LEGACY

        static final String PID_CFG_LOG_READER_SIZE_LEGACY
        org.osp4j.pax.logging PID property to specify max size for LogReaderService
        See Also:
        Constant Field Values
      • PID_CFG_LOG_READER_SIZE

        static final String PID_CFG_LOG_READER_SIZE
        org.osp4j.pax.logging PID property to specify max size for LogReaderService
        See Also:
        Constant Field Values
      • SERVICE_PROPERTY_LAYOUT_NAME_PROPERTY

        static final String SERVICE_PROPERTY_LAYOUT_NAME_PROPERTY
        Service property to filter PaxLayout OSGi services
        See Also:
        Constant Field Values
      • SERVICE_PROPERTY_FILTER_NAME_PROPERTY

        static final String SERVICE_PROPERTY_FILTER_NAME_PROPERTY
        Service property to filter PaxFilter OSGi services
        See Also:
        Constant Field Values
      • EVENT_ADMIN_CONFIGURATION_TOPIC

        static final String EVENT_ADMIN_CONFIGURATION_TOPIC
        EventAdmin topic name to publish events related to (re)configuration of logging backend.
        See Also:
        Constant Field Values
      • LOGGING_CFG_LOGBACK_USE_STATIC_CONTEXT

        static final String LOGGING_CFG_LOGBACK_USE_STATIC_CONTEXT
        Context property that switches from private ch.qos.logback.classic.LoggerContext to one managed by org.slf4j.impl.StaticLoggerBinder#defaultLoggerContext (where StaticLoggerBinder is the one available in logback-classic).
        See Also:
        Constant Field Values
      • LOGGING_CFG_LOGBACK_CONFIGURATION_FILE

        static final String LOGGING_CFG_LOGBACK_CONFIGURATION_FILE
        System or context (in that order) property that sets Logback configuration file (not generic URI - just a path). See https://logback.qos.ch/manual/configuration.html
        See Also:
        Constant Field Values
      • LOGGING_CFG_PROPERTY_FILE

        static final String LOGGING_CFG_PROPERTY_FILE
        System or context property that can indicate alternative file in format specific to the backend used instead of the properties from Configuration Admin. Useful in tests or in environment without Configuration Admin.
        See Also:
        Constant Field Values
      • LOGGING_CFG_LOG4J2_ERRORS_AS_EXCEPTION

        static final String LOGGING_CFG_LOG4J2_ERRORS_AS_EXCEPTION
        System or context property that can indicate whether to throw exceptions from log4j2 configuration methods when ERROR occurs. Normally ERRORs are only printed to org.apache.logging.log4j.status.StatusLogger so by default this value is false.
        See Also:
        Constant Field Values
      • PID_CFG_LOGBACK_CONFIG_FILE

        static final String PID_CFG_LOGBACK_CONFIG_FILE
        org.osp4j.pax.logging PID property to specify XML file with Logback configuration
        See Also:
        Constant Field Values
      • PID_CFG_LOG4J2_CONFIG_FILE

        static final String PID_CFG_LOG4J2_CONFIG_FILE
        org.osp4j.pax.logging PID property to specify XML (or any supported) file (not URL) with Log4J2 configuration. Can be comma-separated and compliant to Log4J2's log4j.configurationFile
        See Also:
        Constant Field Values
      • PID_CFG_LOG4J2_DEFAULTS_FILE

        static final String PID_CFG_LOG4J2_DEFAULTS_FILE
        org.osp4j.pax.logging PID property to specify properties file with default Log4J2 configuration that may be overriden by further configuration in PID file.
        See Also:
        Constant Field Values
      • PID_CFG_LOG4J2_ASYNC

        static final String PID_CFG_LOG4J2_ASYNC
        org.osp4j.pax.logging PID property to specify whether async context should be used. Used both for case where properties are taken directly from PID configuration or when PID_CFG_LOG4J2_CONFIG_FILE is used.
        See Also:
        Constant Field Values
      • PID_CFG_USE_LOCKS

        static final String PID_CFG_USE_LOCKS
        org.osp4j.pax.logging PID property to specify whether to use locks during (re)configuration. By default, log operations use locks to prevent reconfiguration during actual logging. But there are special cases (see: https://ops4j1.jira.com/browse/PAXLOGGING-191) when reconfiguration may lead to calling custom appender code, which start some threads that call yet another code which call log statements. This option may be turned off (value: false) to disable locks.
        See Also:
        Constant Field Values
      • LOGGING_CFG_INHERIT_THREAD_CONTEXT_MAP

        static final String LOGGING_CFG_INHERIT_THREAD_CONTEXT_MAP
        System property to disable (because its enabled by default) thread map inheritance in PaxContext
        See Also:
        Constant Field Values
      • _LOG4J2_MESSAGE

        static final String _LOG4J2_MESSAGE
        Private key to pass original Log4j2 org.apache.logging.log4j.message.Message if it's going to be used by Log4j2 backend (see https://ops4j1.jira.com/browse/PAXLOGGING-302)
        See Also:
        Constant Field Values
      • PAX_LOGGING_PROPERTY_FILE

        static final String PAX_LOGGING_PROPERTY_FILE
        Default file looked up during startup to override Configuration Admin config
        See Also:
        Constant Field Values
      • LOGGING_CFG_ENABLE_EVENT_ADMIN

        static final String LOGGING_CFG_ENABLE_EVENT_ADMIN
        System or context property to disable (because its enabled by default) Event Admin support (even if it's available). If not specified, it is assumed that Event Admin is enabled.
        See Also:
        Constant Field Values
      • LOGGING_CFG_ENABLE_LOG_READER_SERVICE

        static final String LOGGING_CFG_ENABLE_LOG_READER_SERVICE
        System or context property to disable (because its enabled by default) LogReaderService registration. If not specified, it is assumed that this service is registered. This is mandated by OSGi CMPN Log Specification, but impacts performance. So it can be disabled if needed.
        See Also:
        Constant Field Values