Aggregation time complexity

I want to aggregate N(= 10 million) data by percentile_rank. And I want to call this query lively (more than 100 times per second).

As far as I know, Elasticsearch uses t-digest algorithm on percentile. So total time complexity is O(NlogN).

My question is, does this time complexity applies on every single percentile_rank query? Is there any optimization like caching(if no PUT happens), periodical sort(maybe once an hour)?

If there is no optimization, can Elasticsearch handle our query scale effectively?