Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rlqs: implement preview matchers #37900

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

bsurber
Copy link
Contributor

@bsurber bsurber commented Jan 6, 2025

Commit Message:

  • Preview matchers are provided to enable testing how a config would have treated incoming traffic.
    • The preview matcher tree and the actionable matcher tree are both checked against each incoming request.
    • The selected, actionable matcher will always determine the allow/deny decision for the request.
    • The preview matcher will go through full evaluation (bucket usage caching, etc) but the resulting allow/deny decision will not be enforced.
      • Preview matching & evaluation will populate dynamic metadata to make test results visible on the Envoy and the RLQS server will see usage reports, generate responses, etc as normal for server-side visibility.
  • Both the actionable and preview matchers are given an optional priority value, to determine behavior when both the actionable and preview matchers match on a given request.
    • If the selected, actionable matcher has higher priority, then the preview matcher will not be evaluated.
    • If both have the same priority or the preview matcher has higher priority, then both matchers will be evaluated fully.
  • A remaining TODO is to consider cases where the preview and actionable matchers point to the same bucket-id, as currently this gets reported as 2 separate requests to the same bucket. This can be addressed in a number of ways but deduping has a non-zero cost, so the first implementation is starting with the simplest option (no special-case handling).

Risk Level:
Testing: Unit testing, manual testing WIP
Docs Changes:
Release Notes:
Platform Specific Features:

Copy link

As a reminder, PRs marked as draft will not be automatically assigned reviewers,
or be handled by maintainer-oncall triage.

Please mark your PR as ready when you want it to be reviewed!

🐱

Caused by: #37900 was opened by bsurber.

see: more, trace.

Copy link

CC @envoyproxy/api-shepherds: Your approval is needed for changes made to (api/envoy/|docs/root/api-docs/).
envoyproxy/api-shepherds assignee is @markdroth
CC @envoyproxy/api-watchers: FYI only for changes made to (api/envoy/|docs/root/api-docs/).

🐱

Caused by: #37900 was opened by bsurber.

see: more, trace.

@bsurber bsurber marked this pull request as ready for review January 6, 2025 20:28
@bsurber
Copy link
Contributor Author

bsurber commented Jan 6, 2025

Please squash-and-merge when ready, as Commit f521fc8 is a duplicate of the changes from PR #37851 and not needed.

@bsurber
Copy link
Contributor Author

bsurber commented Jan 6, 2025

@sergiitk CC to review the proto changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants