Skip to content

build(deps)!: Upgrade to opentelemetry 0.32 - #23

Merged
open-schnick merged 1 commit into
open-schnick:mainfrom
jens1o:jens1o/upgrade-opentelemetry
Jul 22, 2026
Merged

open-schnick merged 1 commit into
open-schnick:mainfrom
jens1o:jens1o/upgrade-opentelemetry

Conversation

@jens1o

@jens1o jens1o commented May 28, 2026

Copy link
Copy Markdown
Contributor

Upgrades the OTel dependency stack to opentelemetry 0.32 / tracing-opentelemetry 0.33 and bumps the crate to 8.0.0 per the established "OTel minor = breaking" policy.

There was a breaking change in tracing-opentelemetry, see https://github.com/tokio-rs/tracing-opentelemetry/releases/tag/v0.33.0 - I oriented myself after this example to see how they suggest it: https://github.com/tokio-rs/tracing-opentelemetry/blob/1d5422f1f37932fd65e434da618b305d4c94ee9c/examples/otel_context.rs

@jens1o

jens1o commented May 28, 2026

Copy link
Copy Markdown
Contributor Author

I want to test this in my setup using a hot patch in our nonprod-setup, I'll report back whether it works - tests are passing on my local dev machine.

@jens1o

jens1o commented May 28, 2026

Copy link
Copy Markdown
Contributor Author

I can confirm that this works on a nonprod deployment, I used

# Hotpatch: point at jens1o's fork until open-schnick/DatadogFormattingLayer#23
# is merged and a v8 release lands on crates.io.
datadog-formatting-layer = { git = "https://github.com/jens1o/DatadogFormattingLayer.git", rev = "098c2c0bc1dbe0a8b2ff33fbbc131fb92c016dbc" }
# Pinned to match the versions that `datadog-formatting-layer` (PR #23, v8) was
# compiled against. Bumping past these splits the OTel global state into
# two parallel copies and breaks trace ↔ log correlation (the dd layer
# can no longer find the `OtelData` extension the layer wrote in).
opentelemetry = "0.32"
opentelemetry_sdk = { version = "0.32", features = ["rt-tokio"] }
opentelemetry-datadog = { version = "0.20", features = [
    "reqwest-blocking-client",
] }
tracing-opentelemetry = "0.33"

@open-schnick open-schnick left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

So you did verify that logs, traces and log correlation still works? (it should as the tests are not failing, but maybe the other deps changed stuff)

Comment thread Cargo.toml
@jens1o

jens1o commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

Hey @open-schnick,

Thanks for your feedback. I'm sorry for the late reply, I was out sick and hence out of office.

Yes, I did test it using my fork.

@jens1o

jens1o commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

I'll fix the conflict later this day.

@jens1o

jens1o commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

I'd like to test this again with the other dependency upgrades, I'll come back to you when it works. :) Please don't merge yet.

@jens1o
jens1o force-pushed the jens1o/upgrade-opentelemetry branch from 923f6c1 to a206522 Compare July 21, 2026 08:49
@jens1o

jens1o commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

I can confirm logs, tracing and log-tracing-correlation still work on commit 8f99b2a7df0c61b9ba827fa3e5b57b36868deee6.

Feel free to review :)

@jens1o
jens1o requested a review from open-schnick July 21, 2026 09:18
@open-schnick

Copy link
Copy Markdown
Owner

Looks good to me :)
If you cleanup the commits (aka remove the merge commits and rebase instead) we can merge this

BREAKING CHANGE: upgrading the otel version is deemed as breaking as the
otel code might break downstream code silently
@jens1o
jens1o force-pushed the jens1o/upgrade-opentelemetry branch from 8f99b2a to 70d18d6 Compare July 22, 2026 09:29
@jens1o

jens1o commented Jul 22, 2026

Copy link
Copy Markdown
Contributor Author

Sure thing, I have done as such. :) I still have the README change in my commit, I think that's okay.

@open-schnick
open-schnick merged commit 21b583d into open-schnick:main Jul 22, 2026
5 checks passed
@jens1o
jens1o deleted the jens1o/upgrade-opentelemetry branch July 23, 2026 17:26
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

Successfully merging this pull request may close these issues.

2 participants