neo4j/neo4j — pull request #2076 by tinwelint (2014-03-03 16:03:26+00:00)
Title: Ensure index recovery happens after neostore fully recovered

Before this commit the deferred recovery of schema related indexes (done
in IndexingService#start) was done in NeoStoreXaDataSource#start. That
worked fine if the neostore data source could resolve all recovered
transactions by itself, i.e. there were only 1PC transactions or the
encountered 2PC transactions all had their 2PC log entries present.
If not then there were an additional pass where the tx log was consulted
and finally each individual data source was notified about what to do with
the pending transactions. If one or more transactions needed to involve the
tx log then making the neostore "OK" was delayed until after
TxManager#doRecovery had been called.

Now deferred schema index recovery takes place as part of the
TxManager#doRecovery pass and so will always see all recovered
transactions and get the deferred index updates from a fully recovered
store.