I am trying to store my Java Cq engine map on disk. The map is huge and multiple threads are accessing it concurrently.
I am getting:
Caused by: java.sql.SQLException: database is locked
I am doing this to remove clear my heap space. Slow search is not problem.
DiskPersistence<PimcoImsModel, String> persistence = DiskPersistence.onPrimaryKeyInFile(PimcoImsModel.ID, new File(getSourceDb()));
memory = new ConcurrentIndexedCollection<PimcoImsModel> (persistence);