Partial fix for OPENDJ-2190 Delete not replicated after 36h of add/delete operations on replicated topology
Revise the default number of helper threads in replication.
The number of replication replay threads are insufficient to apply updates coming from replication with respect to requests processed by the frontend.
Same as the worker threads, base their number on the number of CPUs in the system.
On replicated instances, the second instance can now keep up with incoming changes more easily.
The original problem could be seen on the machine I used by running the test ( 2 instances + client) restricted to 8 processors out of 32 (2 x 8 cores + MT).
The first instance goes from 500 to 450 Add/s, because the second instance uses more cpu (from half to two thirds of
what was used by the first to a bit less).
As for the number of worker threads, if run with restricted number and full speed:
Worker threads | All processors | Processor set 0-7
---------------+----------------------+----------------------
2 x Ncpus |700 ADD,100K Searches | 450 ADD, 31K searches
1.5 Ncpus |700 ADD, 76K Searches | 450 ADD, 29K searches
On my laptop (4 core + MT), single instance, I see 32K (2 * Ncpus) instead of 29K (1.5 * Ncpus) searches.
By "Add" we mean "addrate load of add/delete spaced by 10000 entries".