Skip to content

Commit a0dd8ba

Browse files
committed
Update action_pack changelog
1 parent 3cd3c0a commit a0dd8ba

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

instrumentation/action_pack/README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,3 +89,21 @@ The `opentelemetry-instrumentation-action_pack` gem is distributed under the Apa
8989
[slack-channel]: https://cloud-native.slack.com/archives/C01NWKKMKMY
9090
[discussions-url]: https://github.com/open-telemetry/opentelemetry-ruby/discussions
9191
[rails-home]: https://rubyonrails.org/
92+
93+
## HTTP semantic convention stability
94+
95+
In the OpenTelemetry ecosystem, HTTP semantic conventions have now reached a stable state. However, the initial Rack instrumentation, which Action Pack relies on, was introduced before this stability was achieved, which resulted in HTTP attributes being based on an older version of the semantic conventions.
96+
97+
To facilitate the migration to stable semantic conventions, you can use the `OTEL_SEMCONV_STABILITY_OPT_IN` environment variable. This variable allows you to opt-in to the new stable conventions, ensuring compatibility and future-proofing your instrumentation.
98+
99+
Sinatra instrumentation installs Rack middleware, but the middleware version it installs depends on which `OTEL_SEMCONV_STABILITY_OPT_IN` environment variable is set.
100+
101+
When setting the value for `OTEL_SEMCONV_STABILITY_OPT_IN`, you can specify which conventions you wish to adopt:
102+
103+
- `http` - Emits the stable HTTP and networking conventions and ceases emitting the old conventions previously emitted by the instrumentation.
104+
- `http/dup` - Emits both the old and stable HTTP and networking conventions, enabling a phased rollout of the stable semantic conventions.
105+
- Default behavior (in the absence of either value) is to continue emitting the old HTTP and networking conventions the instrumentation previously emitted.
106+
107+
During the transition from old to stable conventions, Rack instrumentation code comes in three patch versions: `dup`, `old`, and `stable`. These versions are identical except for the attributes they send. Any changes to Rack instrumentation should consider all three patches.
108+
109+
For additional information on migration, please refer to our [documentation](https://opentelemetry.io/docs/specs/semconv/non-normative/http-migration/).

0 commit comments

Comments
 (0)