Open yzhangyext opened 1 year ago
Hi, thanks for your issue. I don't know that we can change these now unfortunately, it might break existing users. Note that this is just a third party library and you can probably just copy one of the interceptors and change the labels (preserving the license, of course).
I see. In that case, do you think it's a good idea to allow passing in an option to convert these label values to standardized form (upper case)? It would greatly help us grouping metrics between Go and Java services.
I suppose we could consider an option. It looks like the logic for this is here: https://github.com/grpc-ecosystem/go-grpc-middleware/blob/3ade00c067599e45664a46dabe922c8d32b32ddd/providers/prometheus/reporter.go#L31 and here: https://github.com/grpc-ecosystem/go-grpc-middleware/blob/3ade00c067599e45664a46dabe922c8d32b32ddd/interceptors/reporter.go#L16. Please make a more concrete proposal for this option (a PR would do) and we can see if it fits well into the code.
Hi Team, I've noticed a Prometheus label value inconsistency between Go and Java (java-grpc-prometheus): e.g. In metrics
grpc_server_handled_total
, Forgrpc_type
label, Java is uppercase while go is lower case, e.g. "UNARY" vs "unary" Forgrpc_code
label, Java is uppercase while go is camel case, e.g. "UNKNOWN" vs "Unknown" Do you think it's a good idea to have them standardized? I personally prefer the uppercase, but I would love to hear your thoughts on this.