Skip to content

Conversation

@lmolkova
Copy link
Member

@lmolkova lmolkova commented Dec 3, 2024

Part of open-telemetry/opentelemetry-specification#4260

Logs SIG is working on migrating from event.name attribute to EventName field on LogRecord. This is a WIP that depends on the

Creating it to socialize the proposal and gather high-level feedback.

Semantic conventions that depend on event.name (over-the-wire):

Transition

event.name is an experimental attribute and de-facto is used by new-ish conventions and instrumentation libraries.

So we (Logs SIG) believe no common transition/migration plan is necessary, but individual instrumentation libraries can provide back-compat story.

  • Instrumentations that produce events using explicit event.name attribute can do a breaking change and start using LogRecord.EventName property instead of the attribute. It's up to each instrumentation component to provide (or not provide) transition story.
  • Telemetry consumers should expect to receive deprecated event.name attribute, new LogRecord.EventName property or both. When both are present, the LogRecord.EventName should be used as a source of truth.

Future

Instead of deprecating event.name, we might want to reserve it for bridges similarly to otel.status_code. E.g. when users want to report event using logging bridge and the logging facade does not have a notion of event name, the event.name attribute maybe used by the end users and translated to top-level LogRecord property by the adapter.

Deprecating the attribute is reversible, so I'd prefer to do it now and tackle compatibility with external logging libs separately.

Merge requirement checklist

Copy link
Contributor

@breedx-splk breedx-splk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know it's still just draft, but this seems fine.

@lmolkova lmolkova marked this pull request as ready for review December 12, 2024 04:24
@lmolkova lmolkova force-pushed the deprecate-event-name-attribute branch from adf6a98 to 75746bc Compare December 12, 2024 04:59
@lmolkova lmolkova requested a review from a team as a code owner December 12, 2024 04:59
Copy link
Contributor

@breedx-splk breedx-splk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Onward! 🚀

@lmolkova lmolkova force-pushed the deprecate-event-name-attribute branch from a00f928 to 39b2ad9 Compare December 13, 2024 02:31
@lmolkova lmolkova force-pushed the deprecate-event-name-attribute branch from e8148c9 to 11409ed Compare December 13, 2024 18:16
@lmolkova lmolkova merged commit a596f19 into open-telemetry:main Dec 17, 2024
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants