open-policy-agent / opa

Open Policy Agent (OPA) is an open source, general-purpose policy engine.
https://www.openpolicyagent.org
Apache License 2.0
9.56k stars 1.33k forks source link

custom bucket sizes in opa-envoy-plugin #6814

Closed amirsalarsafaei closed 3 months ago

amirsalarsafaei commented 3 months ago

What is the underlying problem you're trying to solve?

In opa-envoy-plugin, the grpc response time metric bucket sizes are hard coded and can't be changed through configuration

Describe the ideal solution

just like the the http histogram in the opa server it can be provided through the configs. if provided use that else use the default value.

Describe a "Good Enough" solution

its the same.

Additional Context

Different use cases require different measurements, as it was assumed in the http response case.

I'd be happy to issue a pull request as the solution needs little effort and I would like to give back to the community

amirsalarsafaei commented 3 months ago

@srenatus I created the PR, I would appreciate it if you found the time to review it