Apply the changes from https://github.com/open-telemetry/opentelemetry-java-instrumentation/pull/14155