Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tags to project metrics #2623

Merged
merged 3 commits into from
Oct 28, 2022
Merged

Conversation

TylerLubeck
Copy link
Contributor

This adds a few tags that I've found useful for our monitoring of a many-project terraform repository. There are likely more tags that can be added in other areas, but I figured I'd start small and get feedback before increasing the blast radius

This adds a few tags that I've found useful for our monitoring of a
many-project terraform repository. There are likely more tags that can
be added in other areas, but I figured I'd start small and get feedback
before increasing the blast radius
@TylerLubeck TylerLubeck requested a review from a team as a code owner October 26, 2022 19:44
nitrocode
nitrocode previously approved these changes Oct 27, 2022
@nitrocode nitrocode dismissed their stale review October 27, 2022 03:56

lets add extra tags

@jamengual jamengual added waiting-on-response Waiting for a response from the user metrics labels Oct 27, 2022
@nitrocode nitrocode merged commit 9ab3fd2 into runatlantis:master Oct 28, 2022
@albertorm95
Copy link
Contributor

lol I was just about to sand a commit with the same thing HAHA, thanks!

@carmennavarreteh
Copy link

@TylerLubeck Hi!, I was trying to test the new tags for prometheus using the pre-release docker image.I was unable to see the tags in the /metrics endpoint. Can you please share how you test it?

@albertorm95
Copy link
Contributor

albertorm95 commented Nov 16, 2022

Hey @TylerLubeck, I was testing v0.21.0-pre.20221114 and v0.20.2-pre.20221106 docker images and I cannot see the tags in the metrics, how is it working?

Metrics
# HELP atlantis_api_getprojectjobs_execution_error atlantis_api_getprojectjobs_execution_error counter
# TYPE atlantis_api_getprojectjobs_execution_error counter
atlantis_api_getprojectjobs_execution_error 1
# HELP atlantis_api_getprojectjobs_execution_time atlantis_api_getprojectjobs_execution_time summary
# TYPE atlantis_api_getprojectjobs_execution_time summary
atlantis_api_getprojectjobs_execution_time{quantile="0.5"} NaN
atlantis_api_getprojectjobs_execution_time{quantile="0.75"} NaN
atlantis_api_getprojectjobs_execution_time{quantile="0.95"} NaN
atlantis_api_getprojectjobs_execution_time{quantile="0.99"} NaN
atlantis_api_getprojectjobs_execution_time{quantile="0.999"} NaN
atlantis_api_getprojectjobs_execution_time_sum 83.875298474
atlantis_api_getprojectjobs_execution_time_count 5
# HELP atlantis_cmd_autoplan_builder_execution_error atlantis_cmd_autoplan_builder_execution_error counter
# TYPE atlantis_cmd_autoplan_builder_execution_error counter
atlantis_cmd_autoplan_builder_execution_error 0
# HELP atlantis_cmd_autoplan_builder_execution_success atlantis_cmd_autoplan_builder_execution_success counter
# TYPE atlantis_cmd_autoplan_builder_execution_success counter
atlantis_cmd_autoplan_builder_execution_success 10
# HELP atlantis_cmd_autoplan_builder_execution_time atlantis_cmd_autoplan_builder_execution_time summary
# TYPE atlantis_cmd_autoplan_builder_execution_time summary
atlantis_cmd_autoplan_builder_execution_time{quantile="0.5"} NaN
atlantis_cmd_autoplan_builder_execution_time{quantile="0.75"} NaN
atlantis_cmd_autoplan_builder_execution_time{quantile="0.95"} NaN
atlantis_cmd_autoplan_builder_execution_time{quantile="0.99"} NaN
atlantis_cmd_autoplan_builder_execution_time{quantile="0.999"} NaN
atlantis_cmd_autoplan_builder_execution_time_sum 59.559332533
atlantis_cmd_autoplan_builder_execution_time_count 10
# HELP atlantis_cmd_autoplan_execution_error atlantis_cmd_autoplan_execution_error counter
# TYPE atlantis_cmd_autoplan_execution_error counter
atlantis_cmd_autoplan_execution_error 0
# HELP atlantis_cmd_autoplan_execution_failure atlantis_cmd_autoplan_execution_failure counter
# TYPE atlantis_cmd_autoplan_execution_failure counter
atlantis_cmd_autoplan_execution_failure 0
# HELP atlantis_cmd_autoplan_execution_success atlantis_cmd_autoplan_execution_success counter
# TYPE atlantis_cmd_autoplan_execution_success counter
atlantis_cmd_autoplan_execution_success 2
# HELP atlantis_cmd_autoplan_execution_time atlantis_cmd_autoplan_execution_time summary
# TYPE atlantis_cmd_autoplan_execution_time summary
atlantis_cmd_autoplan_execution_time{quantile="0.5"} NaN
atlantis_cmd_autoplan_execution_time{quantile="0.75"} NaN
atlantis_cmd_autoplan_execution_time{quantile="0.95"} NaN
atlantis_cmd_autoplan_execution_time{quantile="0.99"} NaN
atlantis_cmd_autoplan_execution_time{quantile="0.999"} NaN
atlantis_cmd_autoplan_execution_time_sum 152.79512225500002
atlantis_cmd_autoplan_execution_time_count 12
# HELP atlantis_cmd_comment_apply_builder_execution_error atlantis_cmd_comment_apply_builder_execution_error counter
# TYPE atlantis_cmd_comment_apply_builder_execution_error counter
atlantis_cmd_comment_apply_builder_execution_error 0
# HELP atlantis_cmd_comment_apply_builder_execution_success atlantis_cmd_comment_apply_builder_execution_success counter
# TYPE atlantis_cmd_comment_apply_builder_execution_success counter
atlantis_cmd_comment_apply_builder_execution_success 3
# HELP atlantis_cmd_comment_apply_builder_execution_time atlantis_cmd_comment_apply_builder_execution_time summary
# TYPE atlantis_cmd_comment_apply_builder_execution_time summary
atlantis_cmd_comment_apply_builder_execution_time{quantile="0.5"} NaN
atlantis_cmd_comment_apply_builder_execution_time{quantile="0.75"} NaN
atlantis_cmd_comment_apply_builder_execution_time{quantile="0.95"} NaN
atlantis_cmd_comment_apply_builder_execution_time{quantile="0.99"} NaN
atlantis_cmd_comment_apply_builder_execution_time{quantile="0.999"} NaN
atlantis_cmd_comment_apply_builder_execution_time_sum 0.16340852600000003
atlantis_cmd_comment_apply_builder_execution_time_count 3
# HELP atlantis_cmd_comment_apply_execution_error atlantis_cmd_comment_apply_execution_error counter
# TYPE atlantis_cmd_comment_apply_execution_error counter
atlantis_cmd_comment_apply_execution_error 1
# HELP atlantis_cmd_comment_apply_execution_failure atlantis_cmd_comment_apply_execution_failure counter

thanks!

krrrr38 pushed a commit to krrrr38/atlantis that referenced this pull request Dec 16, 2022
* Add tags to project metrics

This adds a few tags that I've found useful for our monitoring of a
many-project terraform repository. There are likely more tags that can
be added in other areas, but I figured I'd start small and get feedback
before increasing the blast radius

* Add labels, handle nils, alphabetize

* Move //nolint to line of assignment
@nitrocode nitrocode added this to the 0.21.0 milestone Jan 13, 2023
@nitrocode nitrocode added stats and removed metrics labels Jun 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stats waiting-on-response Waiting for a response from the user
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants