-
Notifications
You must be signed in to change notification settings - Fork 105
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
Add regex matching for headers and query params for HTTPRoute and GRPCRoute #3093
base: main
Are you sure you want to change the base?
Conversation
✅ Deploy Preview will be available once build job completes!
|
ef6d054
to
cd63396
Compare
cd63396
to
a29b3ee
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3093 +/- ##
==========================================
+ Coverage 90.06% 90.08% +0.02%
==========================================
Files 112 112
Lines 11570 11596 +26
Branches 50 62 +12
==========================================
+ Hits 10420 10446 +26
Misses 1089 1089
Partials 61 61 ☔ View full report in Codecov by Sentry. |
a29b3ee
to
136024d
Compare
Since there are no conformance tests for this, it feels like we should probably have a basic functional test for it. Also, the docs changes should be in the docs repo, not here. |
Yeah put them here to be reviewed. Once I have approvals for this PR, i'll open it in the docs repo. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doc changes LGTM, but don't forget to make them in the documentation repository!
https://github.com/nginx/documentation
It should target the ngf release branch, ngf-release-2.0
.
8bc0aa8
to
a1d46ca
Compare
a1d46ca
to
3f49f53
Compare
3f49f53
to
2a8b719
Compare
90bb6cc
to
32f4173
Compare
32f4173
to
4e9fbde
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
Proposed changes
Write a clear and concise description that helps reviewers understand the purpose and impact of your changes. Use the
following format:
Problem: Users want to be able to specify
RegularExpression
as headers and query params type.Solution: Adds functionality to add
RegularExpression
type for headers in HTTPRoutes and GRPCRoutes and query params in HTTPRoutes.Testing: Manual Testing
For HTTPRoutes, manual testing done using Advanced Routing examples
This route configures headers and query params with regex matching for
coffee-v3
svc. If the regex match succeeds we receive a response fromcoffee-v3
svc , otherwise all request are responded bycoffee-v1
Matches the regular expression, responds from
coffee-v3
Does not match the regular expression, response from
coffee-v1
For GRPCRoute, header matching with regular expression we are configuring a
headerRegex
header and request is received bygrpc-backend-2
Matches the regular expression
Does not match the regular expression
Functional Tests
Exact
andRegularExpression
match type.Please focus on (optional): If you any specific areas where you would like reviewers to focus their attention or provide
specific feedback, add them here.
Closes #1965
Closes #3101
Checklist
Before creating a PR, run through this checklist and mark each as complete.
Release notes
If this PR introduces a change that affects users and needs to be mentioned in the release notes,
please add a brief note that summarizes the change.