How to free up write thread queues

Hello,
How do we free or flush the threadpool write queue in Elastic?

Why do you think you need to do this? Why not just drain it by reducing/stopping indexing into Elasticsearch? Which version of Elasticsearch are you using?

Hello @Christian_Dahlqvist

we ending up doing the latter, we stopped the ingest but wouldn't it be better to flush out the write queue instead of having to wait until the queue clears up (after removing ingest)?

Why? Would that not potentially increase the risk of data loss or partial writes?

Because if the cluster is failing to balance because it has filled up queue, it will reject data via thread pool rejections anyways.

I think being able to clear up the queue instead of stopping majority of our data ingestion and also having to wait until the queue clears ups is not ideal.

Or idk, like mentioned this happened to us. It was a lot of effort to balance out the cluster and it was all due to queue being filled after we attempted to ingest new data.

So we stopped the ingest of the new data but that didn't help. In order to get the cluster back to normal, we had to peel majority of our normal data ingestion in order for the cluster to catch up.