You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since #2916, we close the ES client at each observation to avoid memory leak, because at each reconciliation we create a new ES client even if we don't need it.
I think that instead of passing in a fully instantiated client that gets thrown away most of the time, we should pass a function that creates the client if needed only. This is because creating the client still requires some work like adding the certificates to a trust chain and creating a new HTTP client etc.
The text was updated successfully, but these errors were encountered:
barkbay
changed the title
Create an ES client for the observer only if needed
Create an Elasticsearch client for the observer only if needed
May 10, 2023
Since #2916, we close the ES client at each observation to avoid memory leak, because at each reconciliation we create a new ES client even if we don't need it.
cloud-on-k8s/pkg/controller/elasticsearch/observer/manager.go
Lines 78 to 80 in 85aa75b
It had been identified as a first non-optimal remediation that we had to improve, but ultimately we never did.
#2916 (comment):
The text was updated successfully, but these errors were encountered: