manually evict items from memory
starius opened this issue · comments
Boris Nagaev commented
I would like to be able to evict an item (or at least its value) from memory.
Reopening a database as advised in #4 (comment) is suboptimal, as it introduces long pauses and memory usage is still rather high, because items are stored in memory all the time until I call Write
, Flush
and reopen the database.
Can you provide the following methods, please?
func (t *Collection) EvictValue(i *Item)
func (t *Collection) EvictItem(i *Item)
I would call one of them after I call Set
or Get
to reduce memory usage.