You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8-3
Original file line number
Diff line number
Diff line change
@@ -128,9 +128,14 @@ Configure the package that autometrics will use to produce metrics with the `AUT
128
128
129
129
Autometrics makes it easy to identify if a specific version or commit introduced errors or increased latencies.
130
130
131
-
It uses a separate metric (`build_info`) to track the version and, optionally, git commit of your service. It then writes queries that group metrics by the `version` and `commit` labels so you can spot correlations between those and potential issues.
132
-
133
-
The `version` is read from the `AUTOMETRICS_VERSION` environment variable, and the `commit` value uses the environment variable `AUTOMETRICS_COMMIT`.
131
+
It uses a separate metric (`build_info`) to track the version and, optionally, git commit of your service. It then writes queries that group metrics by the `version`, `commit` and `branch` labels so you can spot correlations between those and potential issues.
132
+
Configure the labels by setting the following environment variables:
133
+
134
+
| Label | Run-Time Environment Variables | Default value |
|`commit`|`AUTOMETRICS_COMMIT` or `COMMIT_SHA`|`""`|
138
+
|`branch`|`AUTOMETRICS_BRANCH` or `BRANCH_NAME`|`""`|
134
139
135
140
This follows the method outlined in [Exposing the software version to Prometheus](https://www.robustperception.io/exposing-the-software-version-to-prometheus/).
0 commit comments