Matthias Beyer
8b508fe4c3
This patch changes the filesystem-backend implementation of libimagstore to open files on each read/write rather than holding the file handle in memory at all times. Whenever a lot of imag store entries are read into memory, the imag process may ran out of file descriptors. With this patch applied, a `Store::get()` call on an entry which is not yet in the store cache would cause the file to be read, but the FD being dropped after that. Likewise, a `Store::update()` (which is also called if the imag entry is dropped) would re-open the file on the filesystem and write the contents from the imag store cache back to the file. With this patch, opening hundrets or thousands of imag entries should be no problem anymore, only the available memory should be a limit then. Signed-off-by: Matthias Beyer <mail@beyermatthias.de> |
||
---|---|---|
.. | ||
libimagerror | ||
libimagrt | ||
libimagstore |