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

feat: add new route matching param position #1984

Merged
merged 7 commits into from
Sep 1, 2021

Conversation

lookbrook
Copy link
Contributor

Please answer these questions before submitting a pull request, or your PR will get closed.

Why submit this pull request?

  • Bugfix
  • New feature provided
  • Improve performance
  • Backport patches

What changes will this PR take into?

add a new route matching param position, so that we can use the build-in parameter such as var.server_port

Related issues

fix/resolve #1961

Checklist:

  • Did you explain what problem does this PR solve? Or what new features have been added?
  • Have you added corresponding test cases?
  • Have you modified the corresponding document?
  • Is this PR backward compatible? If it is not backward compatible, please discuss on the mailing list first

@netlify
Copy link

netlify bot commented Jul 14, 2021

✔️ Deploy Preview for apisix-dashboard ready!

🔨 Explore the source changes: d289af4

🔍 Inspect the deploy log: https://app.netlify.com/sites/apisix-dashboard/deploys/612da1ce2ad55c0008b0be5e

😎 Browse the preview: https://deploy-preview-1984--apisix-dashboard.netlify.app/

@codecov-commenter
Copy link

codecov-commenter commented Jul 25, 2021

Codecov Report

Merging #1984 (d289af4) into master (709d815) will increase coverage by 0.61%.
The diff coverage is 85.71%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1984      +/-   ##
==========================================
+ Coverage   66.63%   67.25%   +0.61%     
==========================================
  Files         121      121              
  Lines        3231     3243      +12     
  Branches      787      790       +3     
==========================================
+ Hits         2153     2181      +28     
+ Misses       1078     1062      -16     
Flag Coverage Δ
frontend-e2e-test 67.25% <85.71%> (+0.61%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
web/src/pages/Route/transform.ts 80.87% <81.81%> (+0.98%) ⬆️
...pages/Route/components/Step1/MatchingRulesView.tsx 83.51% <100.00%> (+18.74%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bcdd3b6...d289af4. Read the comment docs.

@juzhiyuan
Copy link
Member

image

see here, need your help to update codes :)

@liuxiran
Copy link
Contributor

Hi @lookbrook , the code looks good to me, would you please add the related test case for this nice feature?

you can refer to

cy.contains('Advanced Routing Matching Conditions')

to create a route with buildin vars and configure it, check if this rule seted successfully, and then change it to another param, check if it can configure successfully.

@lookbrook
Copy link
Contributor Author

Hi @lookbrook , the code looks good to me, would you please add the related test case for this nice feature?

you can refer to

cy.contains('Advanced Routing Matching Conditions')

to create a route with buildin vars and configure it, check if this rule seted successfully, and then change it to another param, check if it can configure successfully.

ok, I will try it

@lookbrook
Copy link
Contributor Author

I am studying, please contact me if something need to modify

@liuxiran liuxiran requested review from LiteSun and bzp2010 August 30, 2021 15:21
@liuxiran
Copy link
Contributor

also cc @Baoyuantop @iamayushdas @guoqqqi for review, thanks a lot

@guoqqqi
Copy link
Member

guoqqqi commented Aug 30, 2021

LGTM!

@liuxiran liuxiran merged commit d3e1861 into apache:master Sep 1, 2021
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.

support add more parameters in advanced routing matching conditions
8 participants