Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adopt OpenTelemetry Logging #146

Closed
1 of 2 tasks
Emily-Jiang opened this issue Nov 27, 2023 · 2 comments
Closed
1 of 2 tasks

Adopt OpenTelemetry Logging #146

Emily-Jiang opened this issue Nov 27, 2023 · 2 comments
Milestone

Comments

@Emily-Jiang
Copy link
Member

Emily-Jiang commented Nov 27, 2023

Description

As a:

  • Application user
  • Specification implementer

...I need to be able to:

use OpenTelemetry Logging in MicroProfile

...which enables me to:

have a consistent obs to have logging, metrics and tracing working together.

@Emily-Jiang
Copy link
Member Author

Emily-Jiang commented Nov 27, 2023

The OpenTelemetry Logs bridge API exists to enable briding logs from other log frameworks (e.g. SLF4J, Log4j, JUL, Logback,e tc) into OpenTelemetry. It does not define new Log APIs. The following shows the entry points.

LoggerProvider (provider.loggerBuilder(instrumentationScopeName)
    -> LoggerBuilder  (loggerBuilder.build())
      ->Logger (logger.logRecordBuilder)
        ->LogRecordBuilder

Supported API Classes

Main API access

  • package io.opentelemetry.api.logs (opentelemetry-api, stable) with the following classes
  • LoggerProvider, LoggerBuilder, Logger, LogRecordBuilder, Serverity - support all of these
  • DefaultLogger, DefaultLoggerProvider (noop classes) - not needed

Supported the injection

  • support the injection of LoggerProvider
    -@Inject LoggerProvider provider

@Emily-Jiang Emily-Jiang added this to the 2.0 milestone Feb 20, 2024
@Emily-Jiang
Copy link
Member Author

This has been done. We have decided not to expose the Logging SPI. See minutes here on 20th May for the details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant