1 | initial version |
To obtain the recorded metric from Micrometer/Prometheus, you can use the Prometheus endpoint to access the data. Here are the steps to follow:
Start the Prometheus server and configure Micrometer to publish its metrics to it.
Access the Prometheus user interface by opening a web browser and navigating to "http://localhost:9090" (or the URL where Prometheus is running).
In the query box, enter the name of the metric you want to retrieve, for example:
my_application_requests_total
Click the "Execute" button. This will show the metric values for the selected time range.
To view the recorded metric data, click the "Graph" tab to display a graph of the metric over time. You can adjust the time range and resolution using the controls below the graph.
To download the metric data, click the "Download" button and select a format (such as CSV or JSON). This will generate a file containing the metric values for the selected time range.