Skip to content

feat(tracing): forward the journey name alongside the journey id - #115

Merged
ngjunsiang merged 1 commit into
mainfrom
feat/journey-name-forwarding
Oct 21, 2026
Merged

ngjunsiang merged 1 commit into
mainfrom
feat/journey-name-forwarding

Conversation

@ngjunsiang

Copy link
Copy Markdown
Contributor

Refs nyjc-computing/campus#952 (the campus-side adoption PR), refs #114 (the name will also ride on the process journey once that lands).

What

When the host stashes a journey name (flask.g.journey_name — set by flask_campus's @journey decorator, or by the journeys middleware adopting X-Journey-Name), SDK calls now forward it as X-Journey-Name next to X-Journey-ID. Child services' spans tag the same journey_name, so journey cards show the human label end to end instead of only on the originating service's span.

Lockstep: JOURNEY_NAME_HEADER = "X-Journey-Name" mirrors campus.audit.middleware.journeys.ACTION_JOURNEY_NAME_HEADER, per the keep-in-lockstep notes both modules already carry for X-Journey-ID.

Testing

  • TestJourneyNameForwarding: name forwarded with the id, no name → no header, and a lockstep pin test on the header constant.
  • Full suite: 298 passed.

When the host stashes a journey name (flask.g.journey_name — set by
flask_campus's @Journey decorator or by the journeys middleware
adopting X-Journey-Name, campus#952), SDK calls forward it as
X-Journey-Name next to X-Journey-ID, so child services' spans tag the
same journey_name and journey cards show the label end to end.

Refs nyjc-computing/campus#952, campus-api-python#114 (the name will
also ride on the process journey once #114 lands).
@ngjunsiang
ngjunsiang merged commit f0af7ad into main Oct 21, 2026
5 checks passed
@ngjunsiang
ngjunsiang deleted the feat/journey-name-forwarding branch October 21, 2026 03:08
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.

1 participant