You will get timing information from Prometheus automatically. Every time your application is scraped the current value of the counter is stored against the scrape time, so if the previous scrape had a value of 100 and it is now 200, you know the increase happened between the two scrapes.
For counters the rate() functions are useful to show how quickly things are changing. On 23 December 2020 13:25:57 GMT, Pramod Kumar <[email protected]> wrote: >Hi , > >I want to add timestamp with the custom metric. For example : I have a >counter as total_orders_placed. >And I need to see the timestamp value when the counter got incremented. >e.g. > >1. total_orders_placed : 100 at 2020-01-23 11:03:02.543 >2. total_orders_placed : 200 at 2020-01-23 11:04:00.123 > >So, I am looking for the counter with the count value as 100 with time >2020-01-23 11:03:02.543. > >Please help me out. >Thanks. > >-- >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 [email protected]. >To view this discussion on the web visit >https://groups.google.com/d/msgid/prometheus-users/8b987c5b-9b39-4c0c-880a-581c4be3f799n%40googlegroups.com. -- Sent from my Android device with K-9 Mail. Please excuse my brevity. -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/21182370-A0EA-4733-AE43-E9592BE03CA7%40Jahingo.com.

