Comments (6)
I think the issue comes from the histogram_quantile function. Seems in the doc it requires sum
instead of average.
Can you curl
the endpoint and paste the result you have for the akka_http_responses_duration_seconds_bucket
metrics ? This will help for investigation.
from akka-http-metrics.
I did try using sum for the histogram_quantile function but it yields the same result.
The result of the metrics endpoint is as follows
# HELP akka_http_connections_active Active TCP connections
# TYPE akka_http_connections_active gauge
akka_http_connections_active 5.0
# HELP akka_http_requests_active Active HTTP requests
# TYPE akka_http_requests_active gauge
akka_http_requests_active 0.0
# HELP akka_http_responses_size_bytes HTTP response size
# TYPE akka_http_responses_size_bytes summary
akka_http_responses_size_bytes{quantile="0.75",} NaN
akka_http_responses_size_bytes{quantile="0.95",} NaN
akka_http_responses_size_bytes{quantile="0.98",} NaN
akka_http_responses_size_bytes{quantile="0.99",} NaN
akka_http_responses_size_bytes{quantile="0.999",} NaN
akka_http_responses_size_bytes_count 1.0
akka_http_responses_size_bytes_sum 81.0
# HELP akka_http_connections_total Total TCP connections
# TYPE akka_http_connections_total counter
akka_http_connections_total 218092.0
# HELP akka_http_responses_duration_seconds HTTP response duration
# TYPE akka_http_responses_duration_seconds histogram
akka_http_responses_duration_seconds_bucket{le="1.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="2.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="3.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="5.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="8.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="13.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="21.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="34.0",} 234400.0
akka_http_responses_duration_seconds_bucket{le="+Inf",} 234400.0
akka_http_responses_duration_seconds_count 234400.0
akka_http_responses_duration_seconds_sum 1.632999999999979
# HELP akka_http_responses_total HTTP responses
# TYPE akka_http_responses_total counter
akka_http_responses_total 234400.0
# HELP akka_http_requests_total Total HTTP requests
# TYPE akka_http_requests_total counter
akka_http_requests_total 234400.0
# HELP akka_http_requests_size_bytes HTTP request size
# TYPE akka_http_requests_size_bytes summary
akka_http_requests_size_bytes{quantile="0.5",} 0.0
akka_http_requests_size_bytes{quantile="0.75",} 0.0
akka_http_requests_size_bytes{quantile="0.9",} 0.0
akka_http_requests_size_bytes{quantile="0.95",} 0.0
akka_http_requests_size_bytes{quantile="0.99",} 0.0
akka_http_requests_size_bytes_count 234400.0
akka_http_requests_size_bytes_sum 425.0
from akka-http-metrics.
Your buckets are actually miss-configured for your usage:
Buckets(1, 2, 3, 5, 8, 13, 21, 34)
tells your smallest bucket is [0s, 1s[
which contains all of your requests.
You'll then not be able to precisely plot the quantiles.
If your timeout is 200ms, I would suggest to define your buckets more like
Buckets(
0.01, 0.02, 0.03, 0.04, 0.05 0.06, 0.07, 0.08, 0.09, 0.1,
0.11, 0.12, 0.13, 0.14, 0.15 0.16, 0.17, 0.18, 0.19, 0.2,
0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1
)
from akka-http-metrics.
Oh ok, my bad. Let me try this out.
from akka-http-metrics.
No worries. The example given in the README is not really meant to be used as is.
Settings is already configured with more sensible defaults here.
Just overwrite what you need.
from akka-http-metrics.
Worked like a dream. Thank you so much for your instant help. Really appreciate it.
from akka-http-metrics.
Related Issues (20)
- Error in stage [fr.davit.akka.http.metrics.core.MeterStage$$anon$1-MeterStage]: No value present HOT 10
- Create grafana dashboard HOT 1
- Hiding metrics route from scrapping HOT 4
- Extension methods from HttpMetrics break Http().newServerAt HOT 5
- Add a method bindFlow(handler: Flow[I,O,Mat]) to HttpMetricsServerBuilder HOT 2
- Getting error when using bindFlow : `.Error in stage [fr.davit.akka.http.metrics.core.MeterStage$$anon$1-MeterStage]: No value present HOT 2
- akka grpc
- 5xx and 4xx responses go to unlabelled when handled with AKKA `ExecutionDirectives.handleExceptions`
- Request/response headers as metric dimensions HOT 2
- Add directive to provide custom dimensions HOT 7
- Status and method labels are swapped in Prometheus metrics
- 1.7.0 not found in repos HOT 2
- bug: prometheus label issues in 1.7.0 HOT 8
- Support for Apache Pekko HOT 4
- StatusGroup / Path for requests? HOT 2
- No akka_http_responses_size_bytes_bucket for streamed endpoints
- Bug 1.4.0: java.lang.IllegalArgumentException: requirement failed: Responses with this status code must have an empty entity HOT 5
- Unable to get started with akk-http-metrics for scala Akka HTTP and prometheus. HOT 17
- Problem with big requests (>~100kb) HOT 9
- Instantiate HttpMetricsNames the same way as HttpMetricsSettings HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from akka-http-metrics.