title: Prometheus & Micrometer : custom timestamp
body: <p>I am writing a program in Java with SpringBoot, using Micrometer for Prometheus. I am using counter method. I was wondering if there was a way to inject custom timestamp into Prometheus with (or even without) micrometer library?</p>
  
  <p>I am new to Prometheus, and I've read some articles making me think that it is possible to set a custom timestamp, such as:</p>
  
  <ul>
  <li><a href="https://prometheus.io/docs/instrumenting/exposition_formats/" rel="nofollow noreferrer">https://prometheus.io/docs/instrumenting/exposition_formats/</a> the timestamp exposition format</li>
  <li><a href="https://github.com/prometheus/client_java/blob/master/simpleclient/src/main/java/io/prometheus/client/Collector.java" rel="nofollow noreferrer">https://github.com/prometheus/client_java/blob/master/simpleclient/src/main/java/io/prometheus/client/Collector.java</a> the collector registry. Should I use this one with a Pushgateway or on its own? How does it work? I didn't manage to find a lot of information about it.</li>
  </ul>
  
  <p>I don't really understand how to use all of this, and which direction should I take.</p>
  
  <p>Thank you very much for your help!</p>