Evaluating and validating lint errors from Promtool

102 views
Skip to first unread message

tejaswini vadlamudi

unread,
Jul 12, 2022, 8:18:31 AM7/12/22
to Prometheus Users
If we run promtool on Envoy proxy,  we get the below lint errors:
  1. no help text
  2. should have "_total" suffix
  3. use base unit "seconds" instead of "days"
  4. metric names should not contain abbreviated units
Not sure if these errors are terrible and have potential issues when Prometheus or any other Prometheus-compatible vendor is used as a metrics collector in the long run.

What do you guys suggest for such a kind of instrumentation pattern?

/Teja

Julius Volz

unread,
Jul 13, 2022, 7:56:21 AM7/13/22
to tejaswini vadlamudi, Prometheus Users
Hi Tejaswini,

I'm not familiar with the exact metrics that Envoy exposes, but it just sounds like they are just not really following the conventions from https://prometheus.io/docs/practices/naming/ correctly for all metrics and not outputting HELP string lines. Now since those are only conventions and optional features, this should not create a problem other than you having a bit of a harder time interpreting and dealing with those metrics. Prometheus-compatible vendors should be able to handle those just fine, otherwise they are not compatible.

Regards,
Julius

--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/4ddd2372-483d-4896-8a19-0a96635fe8e3n%40googlegroups.com.


--
Julius Volz
PromLabs - promlabs.com

tejaswini vadlamudi

unread,
Jul 13, 2022, 11:35:16 AM7/13/22
to Prometheus Users
Thanks Julius for the clarification!

You are right, no problems with metrics collection, storage, and querying with Prometheus for Envoy metrics. But Envoy can surely improve this for better readability.
Here is a GitHub issue (still open) on this matter: https://github.com/envoyproxy/envoy/issues/22130. I'm attaching here promtool errors shared by the issue author.

As a Prometheus user, I believe CNCF projects can include lint tests using Promtool as a quality check. Maybe an item to consider for CNCF tests project (https://github.com/cncf/cnf-testsuite).

Cheers, Teja
promtool_check_exposed_envoy_metrics.txt

jaouad zarrabi

unread,
Sep 25, 2022, 6:27:51 PM9/25/22
to Prometheus Users
BullionStar is Singapore's Premier Bullion Dealer For Sell  : GOLD / SILVER / BARS / COINS
- Over 1,000 Different Products
-  Cash & Bullion Account
- Attractive Prices
- Quick & Easy
-Tax Free Bullion
- Financial Strength
- Global Reach
- Multi-Jurisdiction
https://www.bullionstar.com/?r=27869
Reply all
Reply to author
Forward
0 new messages