[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Syncrepl: full sync vs. delta

Howard Chu wrote:
In fact, running test008 with an accesslog overlay that uses a single mutex on the write ops actually completes faster than normal, because back-bdb never hits any deadlocks. (Quite a bit faster, 2x at least.) So I guess this approach is acceptable.
The assignment of CSNs to operations needs to occur later though. ModRdn is fine, because it doesn't get a CSN until the backend calls slap_modrdn2mods. But Add, Delete, and Modify all assign the CSN in the frontend, before the accesslog's mutex is locked, so CSNs are still allocated in an uncontrolled order. I'm thinking that all of the assignments should be invoked from the backend. But that means that other modules that call into backends would need to do the graduate() call that the frontend does right now. I guess the simplest would be for the accesslog overlay to just replace the CSN the frontend assigned with a new one. Or add a backend flag "SLAP_DBFLAG_DEFER_CSN" that tells the frontend not to assign it, because someone else will. ...?

 -- Howard Chu
 Chief Architect, Symas Corp.  http://www.symas.com
 Director, Highland Sun        http://highlandsun.com/hyc
 OpenLDAP Core Team            http://www.openldap.org/project/