elasticsearch icon indicating copy to clipboard operation
elasticsearch copied to clipboard

[ML] Refactoring http settings and adding stats endpoint

Open jonathan-buttner opened this issue 9 months ago • 1 comments

This PR adds some comments around the connection eviction and keep-alive strategy documentation for the apache http client implementation. I also increased the connection pool limit to exceed a single route's maximum. I've run into a situation during testing where a single service can lease all the connections in the pool and effectively blocking any other services from leasing a connection.

I also created a stats endpoint at /_inference_stats. I was hoping to use /_inference/_stats but theoretically a user could have that as their inference endpoint id 🤷‍♂️

Right now the endpoint returns stats for the internal apache connection pool. I think this could be useful because it could illuminate whether a cluster has reached the maximum connections in the pool.

TODO figure out how to execute the code on each node and aggregate the results.

jonathan-buttner avatar May 02 '24 19:05 jonathan-buttner

@elasticmachine merge upstream

jonathan-buttner avatar May 03 '24 21:05 jonathan-buttner

Pinging @elastic/ml-core (Team:ML)

elasticsearchmachine avatar May 07 '24 12:05 elasticsearchmachine