Trouble filtering plugins by tags parameter
ansakoy opened this issue · comments
Is there an existing issue for this?
- I have searched the existing issues
Kong version ($ kong version
)
3.6.1
Current Behavior
Plugins are not filtered by tags. In response to /plugins?tags=foo
query all existing plugins are returned.
Expected Behavior
The API only returns the records having the provided tag in their tags
field.
Steps To Reproduce
- Create a plugin with a tag:
curl --request POST \
--url http://localhost:8001/plugins \
--header 'Content-Type: application/json' \
--header 'accept: application/json' \
--data '{"name":"rate-limiting","config":{"hour":500,"minute":500},"tags":["foo"]}'
- Create a plugin without a tag:
curl --request POST \
--url http://localhost:8001/plugins \
--header 'Content-Type: application/json' \
--header 'accept: application/json' \
--data '{"name":"acl","config":{"allow":["hello"]}}'
- Send a request to get only the plugin with the
foo
tag:
curl --request GET \
--url 'http://localhost:8001/plugins?tags=foo' \
--header 'accept: application/json'
Anything else?
The instance is running on Debian 12.
It does not reproduce in my environment. Could you share the logs when the issue occurs?
It does not reproduce in my environment. Could you share the logs when the issue occurs?
I'm not sure which logs to look at. Right now the only place I know of is /usr/local/kong/logs
, which in turn contains the following files:
access.log admin_access.log admin_gui_access.log admin_gui_error.log error.log status_error.log
I suppose, I don't need the gui files, nor the access.log. Which leaves me with admin_access.log, error.log, and status_error.log. The latter is empty, error.log only shows some irrelevant entries (much earlier than the time of the request). And tail
for admin_access.log looks like everything is fine:
127.0.0.1 - - [20/Jun/2024:00:21:53 +0300] "GET /plugins HTTP/1.0" 200 16842 "-" "curl/7.64.1"
Am I looking at a wrong file?
Hmmm maybe we can try to take a look into admin_access.log
to see what URL Kong thinks it receives
This issue is marked as stale because it has been open for 14 days with no activity.
Dear contributor,
We are automatically closing this issue because it has not seen any activity for three weeks.
We're sorry that your issue could not be resolved. If any new information comes up that could
help resolving it, please feel free to reopen it.
Your contribution is greatly appreciated!
Please have a look
our pledge to the community
for more information.
Sincerely,
Your Kong Gateway team