Kong / kong-plugin-prometheus

Prometheus plugin for Kong - this plugin has been moved into https://github.com/Kong/kong, please open issues and PRs in that repo
Apache License 2.0
119 stars 57 forks source link

tests(stream) - stream connections are also counted #108

Closed javierguerragiraldez closed 3 years ago

hbagdi commented 3 years ago

The CI has been failing since the https://github.com/Kong/kong-plugin-prometheus/commit/d125bf35ce2b39426609ce09c94ef21771279314 commit. @javierguerragiraldez Could you look into it and see what is wrong here?

javierguerragiraldez commented 3 years ago

AFAICT, some tests verify that failure cases fail exactly as specified, so I haven't been able to run outside of Pongo, which doesn't help when you are developing on the Kong side too. (at least I think it requires pulling Kong from an "official" docker image, not from a local directory or an unmerged branch) I managed to get it passing agains Kong CE, but EE is a different can of worms...

fffonion commented 3 years ago

I think the tests faield because the stream_rpc listener is not defined in custom_template. While CE 2.1.4 where kong.tools.stream_api is not available, it skipps the stream subrequest. But when running with CE >= 2.3, it will suffer same issue with EE. I will try the following thing:

fffonion commented 3 years ago

https://github.com/Kong/kong/pull/6952