chop-dbhi / prometheus-sql

Service that exposes Prometheus metrics for a SQL result set.
BSD 2-Clause "Simplified" License
202 stars 55 forks source link

Showing metrics label values in lower case only #49

Open pradeepcdlm opened 6 years ago

pradeepcdlm commented 6 years ago

Thank you for this work!

Currently, Prometheus-SQL returns all metrics label values in lower case only. It'd be great if Prometheus-SQL returns the metrics value without converting to lower case.

Regards,

bruth commented 6 years ago

Appears to be two locations this is done: https://github.com/chop-dbhi/prometheus-sql/search?q=ToLower&unscoped_q=ToLower. The latter is a check to determine if its a facet or not, the former seems to be the root issue.

pradeepcdlm commented 6 years ago

Thanks, Bruth for this update,

Shall I work on this repo to make configuration settings in the YML file to check to see whether a case conversion can be implemented by conditionally applying the method ToLower()? And also if we get back to you with this change, can you accept our pull request to integrate it into your repo.

Regards,

bruth commented 6 years ago

Yes please do. I think a config flag for this major cycle is the safest to not break anything. For your use case you can "turn it on".

I will certainly review the PR and provide feedback with every intention to merge it.

pschou commented 3 years ago

I've added this feature in pull request #66