mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-03-09 14:34:43 +00:00
The fact that this test randomly uses a relatively large number of nodes and hence Netty worker threads created a problem with running out of direct memory on CI. Tests run with 512M heap (and hence 512M direct memory) by default. On a CI worker with 16 cores, this means Netty will by default set up 32 transport workers. If we get unlucky and a lot of them actually do work (and thus instantiate a `CopyBytesSocketChannel` which costs 1M per thread for the thread-local IO buffer) we would run out of memory. This specific failure was only seen with `NativeRealmIntegTests` so I only added the constraint on the Netty worker count here. We can add it to other tests (or `SecurityIntegTestCase`) if need be but for now it doesn't seem necessary so I opted for least impact. Closes #46803