Reputation: 2939
We are wanting to start using the Solr metrics, example web API call below:
http://localhost:8983/solr/admin/metrics?type=counter&group=core.bookings
We get results back like this from our master
We get metrics like this from our slave that does all the serving
The question is what are the totalTime values measure in? If we presume they are milliseconds, that would mean that each request was taking 0.8 of a day, and that is just not right! Can someone help describe what units of measure the totalTime is in?
Upvotes: -1
Views: 55
Reputation: 52802
After tracing the source, this is based on the value returned from the metrics timing object, which is given in nanoseconds:
long elapsed = timer.stop();
metrics.totalTime.inc(elapsed);
.. so it's nanoseconds, not milliseconds. This seems to make sense if we take the numbers and divided them:
>>> total = 718781574846646
>>> requests = 6789073
>>> total / requests
105873301.82583779
>>> time_per_request = total / requests
>>> time_per_request / 1_000_000_000
0.10587330182583779
.. so about 0.1s per request on average.
Upvotes: 1