Skip to content

Provide LoggingEndpoint #5321

@vpavic

Description

@vpavic

This is driven by discussion in #4486.

I've started some work on a PR but would like to use this issue to discuss the operations this endpoint would provide as well as some implementation details.

This endpoint would be based on Boot's logging abstraction (LoggingSystem) and would provide the following operations:

  • get a list all known loggers
  • get a logger details by its name
  • set level for a give logger

ATM LoggingSystem implementations internally keep their mappings between Boot's LogLevel and their native log levels. This is used when setting the log levels, which is already supported by logging abstraction. However, with this PR logging abstraction would also need to support get operations which in turn requires resolution of log levels in other direction (resolve LogLevel for given native log level).

I've originally considered making the level mappings bi-directional but this isn't possible since the mappings are not one-on-one in LogbackLoggingSystem and JavaLoggingSystem (see LogLevel.FATAL). Other idea would be to keep the cache of Boot's LogLevels for each registered logger. This cache would be initially populated during initialization of LoggingSystem.

@snicoll any thoughts on this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: on-holdWe can't start working on this issue yet

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions