title: Monitor Java web-app using Prometheus
body: <p>I got a simple java web application running on Tomcat which I would like to monitor using <a href="https://prometheus.io/" rel="nofollow noreferrer">Prometheus</a>.
  I added some counters and gauges to my java app using <a href="https://github.com/prometheus/client_java" rel="nofollow noreferrer">the official client</a>, I installed Prometheus on another server and not would like to pull the metrics from my java app using Prometheus.</p>
  
  <p>Prometheus got <a href="https://prometheus.io/docs/instrumenting/exporters/" rel="nofollow noreferrer">tons of exporters</a> but I'm not clear about which one fits my use case.
  I considered using <a href="https://github.com/prometheus/pushgateway" rel="nofollow noreferrer">Prometheus push gateway</a> but according to the <a href="https://prometheus.io/docs/practices/pushing/" rel="nofollow noreferrer">documentation</a> the only valid use case for the Pushgateway is for capturing the outcome of a service-level batch job, which is not my case.
  What should I do in order to pull the metrics from my java app?</p>