Skip to content

feat: redirect plugin support regex#4152

Merged
Yiyiyimu merged 9 commits into
apache:masterfrom
nanamikon:github-redirect-support-regex
May 7, 2021
Merged

feat: redirect plugin support regex#4152
Yiyiyimu merged 9 commits into
apache:masterfrom
nanamikon:github-redirect-support-regex

Conversation

@nanamikon

@nanamikon nanamikon commented Apr 28, 2021

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:

Redirect plugin support regex, similar to the regex_uri in the proxy_rewrite_plugin
Fix #3722 and #4140

Pre-submission checklist:

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

Comment thread apisix/plugins/redirect.lua Outdated
Comment thread apisix/plugins/redirect.lua Outdated
Comment thread apisix/plugins/redirect.lua Outdated
Comment thread apisix/plugins/redirect.lua Outdated
Comment thread apisix/plugins/redirect.lua Outdated
@nanamikon
nanamikon requested a review from tokers April 28, 2021 11:07
@tokers

tokers commented Apr 29, 2021

Copy link
Copy Markdown
Contributor

@nanamikon CI failed, please check it out.

@nanamikon

nanamikon commented Apr 29, 2021

Copy link
Copy Markdown
Contributor Author

I have fixed it, but how to do with this problem (Semantic Pull Request — add a semantic PR title)

@Gary-Airwallex

Copy link
Copy Markdown
Contributor

I have fixed it, but how to do with this problem (Semantic Pull Request — add a semantic PR title)

Could it be a missing space between feat: and redirect? LOL

Comment thread apisix/plugins/redirect.lua Outdated
Comment thread apisix/plugins/redirect.lua Outdated
Comment thread apisix/plugins/redirect.lua Outdated
@spacewander spacewander changed the title feat:redirect plugin support regex feat: redirect plugin support regex Apr 29, 2021
Comment thread apisix/plugins/redirect.lua Outdated
Comment thread t/plugin/redirect.t Outdated
@nanamikon

nanamikon commented Apr 29, 2021

Copy link
Copy Markdown
Contributor Author

Thanks for review, how can I find this bad style before submit a pr? I have tried luacheck and learned from proxy-rewrite.lua, is there any other tools or docs that I can refer to?

@Firstsawyou

Copy link
Copy Markdown
Contributor

Thanks for review, how can I find this bad style before submit a pr? I have tried luacheck and learned from proxy-rewrite.lua, is there any other tools or docs that I can refer to?

You can refer to this doc: https://github.com/apache/apisix/blob/master/CODE_STYLE.md

@juzhiyuan juzhiyuan left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM from codes logic

Comment thread docs/zh/latest/plugins/redirect.md Outdated
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.

allow using regex in the redirect plugin

7 participants