Hello, Recently I checked what percent of the MongoDB reads are done from the secondary instance in a global clustering setup of the AEM with the recent Oak 1.3.x. It was about 3%.
In the current trunk we'll only read document from the secondary instance if: (1) we have the parent of the document cached and (2) the parent hasn't been modified in 6 hours. The OAK-2106 tried to optimise (2) by estimating lag using MongoDB replica stats. It was unreliable, so the second approach was to read the last revisions directly from each Mongo instance. If the modification date of P is before last revisions on all secondary Mongos, then secondary can be used. The main problem with this approach is that we still need to have the P to be in cache. I think we need a better way to optimise this. Therefore I created OAK-3865. It would be great if you can read the issue description and point out flawes :) Best regards, Tomek -- Tomek Rękawek | Adobe Research | www.adobe.com [email protected]
