We are using curl calls to couchbase FTS index from different users. Is there any way to calculate how many curl POST requests are coming for the index per second given the time stamp range?
For every FTS index, a stat called “total_queries” is supported. This tells you the total number of queries executed against a specific index. Here’s an endpoint that’ll get you the stats -
The stat of interest would look like this -
You should be able to fetch these stats yourself at different times to estimate the number of requests within a time range.
Is there any way to reset this to zero?
nope, there is no way to reset than to restart the server.
There are some graphs like the queries per sec in the stats page. You may check that too. But it is naive and don’t take any start/end timestamps. It just has fixed durations.
For your requirement, you may either need to use third party tools or track this at the client side.
Okay, I will try to get nsstats at different times and estimate no. of requests in that time range. Then I can easily get avg transactions per second.