Now for what concern the Samba4 problem, I think we should be more
creative and first understand in which cases we might hit a problem with
plugins like memberOf. I am sure some of these cases are just normal
possible inconsistencies that can happen even in a normal AD server if
you do many modifications at the same time. For these cases we just have
to try not to make them more probable or problematic than what they are
now.
In other cases we might think of doing aggressive caching/prediction in
our internal transactions. It might require some more work, but it could
be a viable option, and also drive some more performance as dealing with
an external LDAP is necessarily slower.
Finally, if caching/prediction is not possible, we can think of writing
overlays/slapi plugins directly for the LDAP server of choice be it
OpenLDAP or Fedora Directory Server or anything else. This third option
would require some more work and will be server specific, and perhaps
involve some creative thinking wrt licensing, but it is certainly a
viable option we should not discard. After all, these LDAP servers have
a plugin system with defined APIs exactly to solve those problems that
cannot be solved merely by external interaction.