title: How can I create a Micrometer gauge from an async value?
body: <p>I have a reactive Spring Webflux application with Micrometer.<br>
  I want to create a &quot;gauge&quot; metric like:</p>
  <pre><code>Gauge gauge = Gauge
    .builder(&quot;gaugeName&quot;, list, List::size)
    .register(registry);
  </code></pre>
  <p>or a supplier version like:</p>
  <pre><code>Gauge gauge = Gauge
    .builder(&quot;gaugeName&quot;, () -&gt; getValue())
    .register(registry);
  </code></pre>
  <p>However, I have an async source of the value, i.e. a method that returns a Mono.<br>
  How can I create a Micrometer gauge from an async value?</p>