I have a doubt about cache.
The Environment is transactional and the configuration is the default options.
I have Primary Index like that:
private PrimaryIndex<Long, EnSomeEntity> pkSomeEntityById;
I did record on it about 100000000 (one hundred million) elements.
A huge amount of data about 80G of data.
1- I did a count on it it returned the one hundred million elements count but id delayed about 15 minutes.
How I did:
pkSomeEntity.count();
2- I did the count again and it returned in 8 seconds.
3- I did restart the machine; now I did the count on it it delayed about 15 minutes again.
4- I did the sarch again (after restarting) the count returned in 8 seconds.
This cache is handled by the Berkeley DB or it is the Disk Cache. (the disk is not SDD, it's a 'normal' SATA).
What's the best way to handle cache with this huge amount of data?