Make Nexus work OOTB with token-based callback routing#9513
Merged
Conversation
chaptersix
reviewed
Mar 13, 2026
chaptersix
reviewed
Mar 13, 2026
|
|
||
| // routeSystemCallbackRequest routes a system callback request to the appropriate frontend client | ||
| // based on the callback token's namespace and active cluster. | ||
| func routeSystemCallbackRequest( |
Contributor
There was a problem hiding this comment.
I'd prefer that we could export this function somewhere and call it in chasm/ and components/
not blocking
Member
Author
There was a problem hiding this comment.
Yeah, it's possible to remove some duplication here. The idea was to completely decouple the code as the HSM implementation will be deprecated soon and may stop receiving updates and diverge.
chaptersix
approved these changes
Mar 13, 2026
0c39da3 to
4840413
Compare
Refactor system callback URL handling from routeRequest into a dedicated routeSystemCallbackRequest function that routes based on callback token namespace and active cluster. Update both components/callbacks and chasm/lib/callback packages to use namespace registry and callback token generator for routing decisions. Add unit tests covering external targets, local/unknown cluster routing, nil headers, invalid tokens, namespace not found, and success paths.
4840413 to
3f5ea56
Compare
birme
pushed a commit
to eyevinn-osaas/temporal
that referenced
this pull request
Mar 23, 2026
## Summary - Use the system callback URL by default now that the previous minor supports it (1.30) - Extract system callback URL handling from `routeRequest` into a dedicated `routeSystemCallbackRequest` function that routes based on callback token namespace and active cluster - Update both `components/callbacks` and `chasm/lib/callback` packages to use namespace registry and callback token generator for routing decisions - Add unit tests for `routeRequest` and `routeSystemCallbackRequest` covering external targets, local/unknown cluster routing, nil headers, invalid tokens, namespace not found, and success paths ## Test plan - [x] Unit tests added for both `components/callbacks` and `chasm/lib/callback` packages - [x] All 18 tests pass (9 per package) - [x] `make lint` passes with no new issues
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.
Summary
routeRequestinto a dedicatedrouteSystemCallbackRequestfunction that routes based on callback token namespace and active clustercomponents/callbacksandchasm/lib/callbackpackages to use namespace registry and callback token generator for routing decisionsrouteRequestandrouteSystemCallbackRequestcovering external targets, local/unknown cluster routing, nil headers, invalid tokens, namespace not found, and success pathsTest plan
components/callbacksandchasm/lib/callbackpackagesmake lintpasses with no new issues