-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
fix(admin) disable plugin names in /api/:id/plugins* #2726
Conversation
kikito
commented
Jul 24, 2017
•
edited
Loading
edited
- Reverts the main part of fix(admin) disable plugin names in /api/:id/plugins* #2726
- Needs to be merged before feat(admin) add /consumers/:id/plugins routes #2714 in order to make its tests pass
52a157b
to
789c6f7
Compare
789c6f7
to
2ad1152
Compare
(Slightly reworked this to better follow the conventions of |
Actually it seems that this change in general - and not my latest additions - broke the invalidations tests, since those rely on the plugin by name feature for now. |
@thibaultcha I changed the invalidation tests so they didn't rely on the plugin names. I'm leaving that on a separate commit, hoping it is alright. |
@kikito I think it's fine if those are part of the same commit. The scope being "disabling feature X", we should not leave the state of the repo in a non-working state after the related commit is done (harder to detect changes with |
ebc0e1b
to
7b2523f
Compare
7b2523f
to
2428275
Compare
In the `/apis/:api/plugins/:plugin` endpoint, #2252 recently introduced the possibility to pass a plugin name as `:plugin`, instead of an id only. Like: `/apis/:api/plugins/basic-auth`. However, the following minimally reproducible example exposes the flaw with such an endpoint given the current model: ``` $ http POST :8001/apis/ name=api1 hosts=example.com upstream_url=http://httpbin.org $ http POST :8001/consumers name=peter $ http POST :8001/consumers name=mary $ http POST :8001/plugins name=request-size-limiting api_id=$API1_UUID consumer_id=$PETER_UUID $ http POST :8001/plugins name=request-size-limiting api_id=$API1_UUID consumer_id=$MARY_UUID $ http :8001/apis/$API1_UUID/plugins $ http :8001/apis/$API1_UUID/plugins/request-size-limiting ``` Reverts the main part of #2252 Signed-off-by: Thibault Charbonnier <[email protected]>
2428275
to
8403f3b
Compare