First of all thank you for the great library James.
I have one problem with it though which currently makes it unusable for me.
Basically my use case is caching files up to 300kb in the Barrel (I store objects containing some information fields and the large byte array).
On iOS if i cache files, restart the App and then access the files again with Barrel.Current.Get the CPU usage of the app jumps up to over 100% and doesn't go down until i close the app again. This only happens after a restart.
Additionally it doesn't happen if I'm caching small information files.
I'm absolutely sure that the CPU spike is caused by the Barrel call, as soon as i deactivate the Barrel call and use dummy data instead the CPU spike does not occur.
Is my use case simply not fitting for this library?
PS: I tried all 3 different implementations of MonkeyCache (LiteDB, SQLite, FileStorage)
EDIT: I found the problem: In the object strucutre that i cached in the Barrel i had a ManualResetEvent (which makes no sense to put in the cache actually). After setting this to ManualResetEvent to null the problem doesnt occur anymore.
First of all thank you for the great library James. I have one problem with it though which currently makes it unusable for me. Basically my use case is caching files up to 300kb in the Barrel (I store objects containing some information fields and the large byte array). On iOS if i cache files, restart the App and then access the files again with Barrel.Current.Get the CPU usage of the app jumps up to over 100% and doesn't go down until i close the app again. This only happens after a restart. Additionally it doesn't happen if I'm caching small information files. I'm absolutely sure that the CPU spike is caused by the Barrel call, as soon as i deactivate the Barrel call and use dummy data instead the CPU spike does not occur.
Is my use case simply not fitting for this library?
PS: I tried all 3 different implementations of MonkeyCache (LiteDB, SQLite, FileStorage)
EDIT: I found the problem: In the object strucutre that i cached in the Barrel i had a
ManualResetEvent
(which makes no sense to put in the cache actually). After setting this toManualResetEvent
to null the problem doesnt occur anymore.