Ticket 47973 - During schema reload sometimes the search returns no results
Bug Description: During a schema reload operation the search of an existing
entry may randomly report no results. This is because during
the schema reload all existing attribute syntaxes are removed,
and there is a small window where ldap operations can be performed
before the new schema is loaded. During this window, attribute
values are normalized to NULL which causes operation to unexpectedly
fail.
Fix Description: Instead of wiping out the existing attribute syntax hastables
in the middle of the task, instead load the new schema into
temporary hash tables. Once the reload is complete, then take
the asi write lock, remove the old hash tables, and swap in the
new ones.
https://fedorahosted.org/389/ticket/47973
valgrind: PASSED
Reviewed by: nhosoi(Thanks!)
(cherry picked from commit e0c78e1c1db351ea5cf835cdb55437b1ea26a3a6)