Add River RPC span classification attributes#383
Closed
daweifeng-replit wants to merge 1 commit into
Closed
Conversation
darshkpatel
approved these changes
Jun 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
River spans already identify procedure type through
river.method.kind, but the attribute is easy to miss when building Datadog queries and does not include standard RPC semantic fields. Adding explicit RPC classification attributes makes it easier to distinguish unary calls from subscriptions and streams in trace analysis and span-based metrics.What changed
river.method.*attributes for compatibility.rpc.system,rpc.service, andrpc.methodsemantic attributes.river.rpc.kindwith the River procedure kind:rpc,upload,subscription, orstream.river.rpc.streamingso callers can filter streaming procedures with one low-cardinality boolean.Test plan
Verified by CI (no reviewer action needed):
npm run test:single -- tracing/tracing.test.tspasses locally and validates the emitted client/server span attributes.For the reviewer to verify:
Versioning
Revertibility
Safe to revert. This only adds span attributes and a test; it does not change protocol behavior or public TypeScript APIs.
~ written by Zerg 👾 (mutated-zealot-0503)