Database and memory management
The .vjr file is the database file that contains both the strategy and dag graphs and all of the data and models generated. If phasertng has a mechanism that ensures that UUID for data is corresponding uniquely to a specific data operation then we can ensure that no multime entries of the same thing are stored in the database.
Voyager has to maintain some files in memory to speed up the process. the operation of saving a file into the disk can be reduced must be performed every time but files are maintained in memory and accessed from this memory dictionary when needed until more space is required.
- Create a memory object which can occupy a certain amount of memory configured
- Memory is checked at every object access and freed if it is necessary
- Files in memory will be associated with a score that includes a frequency access counter, the timestamp, size in bytes This score should prefer to maintain in-memory high frequently accessed data, possibly recent, that occupy larger memory (and thus would require more time to read and write them from the disk). Finally based on this score we can sort them and decide what free.