]
Ryan Emerson updated ISPN-10423:
--------------------------------
Status: Pull Request Sent (was: Open)
Git Pull Request:
RocksDB ReadOptions memory leak
-------------------------------
Key: ISPN-10423
URL:
https://issues.jboss.org/browse/ISPN-10423
Project: Infinispan
Issue Type: Bug
Components: Loaders and Stores
Affects Versions: 10.0.0.Beta4, 9.4.15.Final
Reporter: Ryan Emerson
Assignee: Ryan Emerson
Priority: Major
Fix For: 10.0.0.Beta5, 9.4.16.Final
Currently our rocksdb store impl creates a new ReadOptions instance per iterator created.
As per the RocksDB we should be calling {{dispose()}} on this once it goes out of scope,
so that the c++ underlying impl can free the memory. Currently we're not doing this,
resulting in a memory leak.
As we only ever use the same ReadOptions for all iterators, we should simply re-use a
singleton for all iterators and then dispose of this on shutdown.