Skip to content

Use preferred_protocols and refactor matching loop in issuance_main#213

Open
netheril96 wants to merge 1 commit into
wasm-pr-metadatafrom
wasm-pr-preferred-protocols
Open

Use preferred_protocols and refactor matching loop in issuance_main#213
netheril96 wants to merge 1 commit into
wasm-pr-metadatafrom
wasm-pr-preferred-protocols

Conversation

@netheril96

Copy link
Copy Markdown
Collaborator

Renamed allowed_protocols to preferred_protocols in IssuanceMatcherData. Updated matching logic: if preferred_protocols is set, we match in order of preference; record the matched request index as pidx in the metadata. Refactored the matching loop in issuance_main using iterator combinators (find_map, find) for better readability. Updated existing tests and added a new test match_preferred_protocol_order to verify preference ordering and pidx recording.

TAG=agy

CONV=6222f947-d807-4f7a-8223-5f30b7376340

@gemini-code-assist

Copy link
Copy Markdown

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@netheril96
netheril96 requested a review from QZHelen July 23, 2026 08:40
@netheril96

netheril96 commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator Author

Note: don't merge this PR as of now because it has a diffbase. Give me comments or approval instead.

Renamed allowed_protocols to preferred_protocols in IssuanceMatcherData.
Updated matching logic:
- If preferred_protocols is set, we match in order of preference.
- Record the matched request index as ridx in the metadata.
Refactored the matching loop in issuance_main using iterator combinators (find_map, find) for better readability.
Updated existing tests and added a new test match_preferred_protocol_order to verify preference ordering and ridx recording.

TAG=agy
CONV=6222f947-d807-4f7a-8223-5f30b7376340
@netheril96
netheril96 force-pushed the wasm-pr-preferred-protocols branch from 2dd3e6b to 8190292 Compare July 23, 2026 13:51
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