make file based history cache creation synchronous
Merge pull request #742 from vladak/filebased_wait

Filebased wait