Skip to content

feat: support X-Amp-Thread-Id for session affinity#2972

Open
XYenon wants to merge 2 commits intorouter-for-me:devfrom
XYenon:feat/amp-thread-id
Open

feat: support X-Amp-Thread-Id for session affinity#2972
XYenon wants to merge 2 commits intorouter-for-me:devfrom
XYenon:feat/amp-thread-id

Conversation

@XYenon
Copy link
Copy Markdown
Contributor

@XYenon XYenon commented Apr 23, 2026

feat: support extracting X-Amp-Thread-Id header as session id for session affinity

@github-actions github-actions Bot changed the base branch from main to dev April 23, 2026 05:52
@github-actions
Copy link
Copy Markdown

This pull request targeted main.

The base branch has been automatically changed to dev.

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the X-Amp-Thread-Id header as a new source for session ID extraction, ranking it third in priority. The changes include updates to the extraction logic in extractSessionIDs, corresponding documentation updates, and new unit tests to verify both the extraction and its priority relative to other identifiers. Feedback suggests standardizing the header name to X-Amp-Thread-ID (capitalized 'ID') to maintain consistency with Go naming conventions and existing headers like X-Session-ID.

Comment thread sdk/cliproxy/auth/selector.go
Comment thread sdk/cliproxy/auth/selector.go
Comment thread sdk/cliproxy/auth/selector_test.go
@XYenon XYenon marked this pull request as draft April 23, 2026 07:19
@XYenon XYenon marked this pull request as ready for review April 23, 2026 07:32
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