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

Implement metrics routes #696

Open
wants to merge 5 commits into
base: develop
Choose a base branch
from

Conversation

Tchoupinax
Copy link

@Tchoupinax Tchoupinax commented Jun 28, 2023

Hey,

Following the previous aborted try to implement the /metrics/ route, this pull request brings this feature.

Added metrics

  • Default Node.js metrics
  • Histogram about response duration
response_duration_bucket{le="0.005",method="GET",path="/api/v2/metrics",status="200"} 41
response_duration_bucket{le="0.01",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="0.025",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="0.05",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="0.1",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="0.25",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="0.5",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="1",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="2.5",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="5",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="10",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_bucket{le="+Inf",method="GET",path="/api/v2/metrics",status="200"} 42
response_duration_sum{method="GET",path="/api/v2/metrics",status="200"} 0.136589004
response_duration_count{method="GET",path="/api/v2/metrics",status="200"} 42
  • Count of created links
# HELP link_counter Number of link created
# TYPE link_counter counter
link_counter 4

* feat: add counter for number of link created

* chore: took in account feedback

---------

Co-authored-by: ImOverlord <thibault-alexandre.faure@swan.io>
@Tchoupinax
Copy link
Author

Hey,
It is ready to be reviewed and to bring a first valued step!
Thank you a lot

@nlamirault
Copy link

@poeti8 what do you think about this feature ?

ImOverlord and others added 2 commits December 15, 2023 08:33
Co-authored-by: ImOverlord <thibault-alexandre.faure@swan.io>
Co-authored-by: ImOverlord <thibault-alexandre.faure@swan.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants