Closed posborne closed 4 years ago
@ustulation Can I get a review on this; it should be noted that the cache implementation is fundamentally broken without some change.
I'm a user of the lru_time_cache library and I would like to see this bug fixed.
I chose the lru_time_cache library due to its lack of unsound unsafe code. There's not that many lru caches in rust. Thank you for providing and maintaining it! I hope it's not rude to ping this issue after 3 months :)
Resolved by #126 , thanks to @calavera New release to follow
These changes aim to make it so that calls to the public API operate over the cache using a single Instant of time rather than calling Instant::now() at several unique points in time during the synchronous execution of the function.
The former execution model lead to potential bugs, notably in functions like entry() as brought up in #122, especially on targets with less processing power or under heavy load.
This also reduces the number of system calls that need to be made which may improve performance for some use cases.