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

proxy api: support destination ip/port matching #9485

Merged
merged 73 commits into from
Jun 5, 2024

Conversation

stevenctl
Copy link
Contributor

@stevenctl stevenctl commented May 14, 2024

Description

Allow filter chain matches to match on destination IP/port.

This bug fixes ... \ This new feature can be used to ...

API changes

In Matcher added:

  • uint32 destination_port
  • CidrRange[] prefix_ranges

(continuing to duplicate what envoy has)

Code changes

Implement the translation from Proxy to Envoy xDS for the new fields.
This was only done in the same places that SourcePrefixRanges were already uses.

Context

Related to #9471

Interesting decisions

We chose to do things this way because ...

Testing steps

I manually verified behavior by relying on it in an experimental fork.

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

@stevenctl stevenctl requested a review from a team as a code owner May 14, 2024 21:23
@github-actions github-actions bot added the keep pr updated signals bulldozer to keep pr up to date with base branch label May 14, 2024
@stevenctl stevenctl requested review from jenshu and sam-heilbron May 14, 2024 21:25
Copy link

github-actions bot commented May 14, 2024

Visit the preview URL for this PR (updated for commit f02fbf5):

https://gloo-edge--pr9485-stevenctl-proxy-matc-1bxrsouj.web.app

(expires Wed, 12 Jun 2024 22:21:29 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 77c2b86e287749579b7ff9cadb81e099042ef677

Copy link
Contributor

@sam-heilbron sam-heilbron left a comment

Choose a reason for hiding this comment

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

Changes LGTM! Could we add some basic unit tests to demonstrate the new matching capabilities and perhaps an e2e test as well to show that the traffic is routed appropriately? https://github.com/solo-io/gloo/blob/main/test/e2e/hybrid_test.go#L172 Might be a good set of tests to build off of

@stevenctl stevenctl force-pushed the stevenctl/proxy-matchers branch from d025d49 to 346e5e6 Compare May 16, 2024 18:40
@stevenctl
Copy link
Contributor Author

@sam-heilbron should be good to go

projects/gateway/api/v1/gateway.proto Outdated Show resolved Hide resolved
projects/gateway/api/v1/gateway.proto Outdated Show resolved Hide resolved
projects/gateway/api/v1/gateway.proto Outdated Show resolved Hide resolved
@stevenctl
Copy link
Contributor Author

ping @lgadban @EItanya looks like the reviews are stale due to auto-updater?

Copy link
Contributor

@Rachael-Graham Rachael-Graham left a comment

Choose a reason for hiding this comment

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

docs

projects/gloo/api/v1/proxy.proto Outdated Show resolved Hide resolved
projects/gloo/api/v1/proxy.proto Outdated Show resolved Hide resolved
projects/gloo/api/v1/proxy.proto Show resolved Hide resolved
lgadban
lgadban previously approved these changes Jun 5, 2024
Copy link
Contributor

@lgadban lgadban left a comment

Choose a reason for hiding this comment

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

LGTM but looks like codegen needs to run (again for some reason).
I'll approve now but can reapprove when CI passes

projects/gloo/api/v1/proxy.proto Show resolved Hide resolved
@EItanya
Copy link
Contributor

EItanya commented Jun 5, 2024

I'm also happy to approve once dogs are fixed

@lgadban
Copy link
Contributor

lgadban commented Jun 5, 2024

@EItanya

I'm also happy to approve once dogs are fixed

which dogs are you referring to? :)

@lgadban
Copy link
Contributor

lgadban commented Jun 5, 2024

buildbot?

@stevenctl stevenctl merged commit 8532dac into main Jun 5, 2024
24 checks passed
@stevenctl stevenctl deleted the stevenctl/proxy-matchers branch June 5, 2024 22:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
keep pr updated signals bulldozer to keep pr up to date with base branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants