fix nodestore for the multithreaded case