apache / ignite

Apache Ignite
https://ignite.apache.org/
Apache License 2.0
4.83k stars 1.9k forks source link

Correct documentation for DFLT_REBALANCE_THREAD_POOL_SIZE #11484

Closed jamnaritesh closed 2 months ago

jamnaritesh commented 3 months ago

Hi, First of all thank you for the amazing project, I've been using it for past 4 years in our production loads and absolutely love working with it. I'm working on upgrading our cluster from 2.3.0 to 2.15.0 and going through the docs.

Just found out that there's a discrepancy between the documentation and defaults used in code.

The doc says: By default, rebalancing is performed in one thread on each node. It means that at each point in time only one thread is used to transfer batches from one node to another, or to process batches coming from the remote node

https://ignite.apache.org/docs/2.15.0/data-rebalancing#configuring-rebalance-thread-pool

However, I can see in the code that the default size of thread-pool will be minimum 4 for any machine with 16 or more cores.

https://github.com/apache/ignite/blob/2.15.0/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java#L169

public static final int DFLT_REBALANCE_THREAD_POOL_SIZE = min(4, max(1, AVAILABLE_PROC_CNT / 4));

Happy to contribute and raise a PR if my understanding is correct :)

sk0x50 commented 3 months ago

Hello @jamnaritesh ,

Yes, your understanding is correct. The documentation should be fixed. Thank you for pointing this out!

Thanks, S.

sk0x50 commented 3 months ago

Hi @IgGusev ,

Could you please take a look and assist with that?

UPDATE: https://issues.apache.org/jira/browse/IGNITE-23149