Vlad Zolotarov
945d26e4ee
loading_cache: make iterator work on top of lru_list iterators instead of loading_shared_values'
...
Reloading may hold value in the underlying loading_shared_values while
the corresponding cache values have already been deleted.
This may create weird situations like this:
<populate cache with 10 entries>
cache.remove(key1);
for (auto& e : cache) {
std::out << e << std::endl;
}
<all 10 entries are printed, including the one for "key1">
In order to avoid such situations we are going to make the loading_cache::iterator
to be a transform_iterator of lru_list::iterator instead of loading_shared_values::iterator
because lru_list contains entries only for cached items.
Signed-off-by: Vlad Zolotarov <vladz@scylladb.com >
2018-08-30 20:56:44 -04:00
..
2017-12-08 13:38:13 -05:00
2018-05-09 16:52:26 +01:00
2018-05-30 12:18:56 +02:00
2017-11-21 16:05:43 +02:00
2017-11-12 15:51:29 +01:00
2016-04-08 08:12:47 +03:00
2016-04-08 08:12:47 +03:00
2018-05-10 09:47:41 +03:00
2018-05-10 09:47:41 +03:00
2016-04-08 08:12:47 +03:00
2018-04-16 21:11:13 +02:00
2018-04-16 21:11:13 +02:00
2018-07-11 16:55:20 +02:00
2018-06-27 14:16:50 +03:00
2018-02-07 10:11:46 +00:00
2018-03-19 12:24:04 +00:00
2018-04-02 19:23:06 +01:00
2018-05-30 14:41:40 +02:00
2017-12-08 13:38:13 -05:00
2016-04-08 08:12:47 +03:00
2016-04-08 08:12:47 +03:00
2017-04-17 23:03:15 +03:00
2017-05-17 12:30:03 +03:00
2018-04-07 14:52:58 +03:00
2018-04-07 14:52:58 +03:00
2017-11-22 16:55:55 +01:00
2016-06-09 10:03:04 +02:00
2016-06-09 09:58:00 +02:00
2018-01-29 10:50:01 +00:00
2018-05-03 17:05:06 -07:00
2017-12-14 15:05:48 -05:00
2016-04-08 08:12:47 +03:00
2017-05-21 12:26:15 +03:00
2018-02-19 13:09:11 +00:00
2018-07-18 12:28:06 +01:00
2018-07-18 12:28:06 +01:00
2016-04-18 13:51:15 +00:00
2017-05-21 12:26:15 +03:00
2018-05-10 09:47:41 +03:00
2018-05-10 09:47:41 +03:00
2017-12-05 14:28:34 +00:00
2016-09-28 17:34:16 +03:00
2017-06-24 18:06:11 +02:00
2016-04-08 08:12:47 +03:00
2018-04-10 10:25:06 +03:00
2018-05-15 11:22:21 -04:00
2016-11-14 18:01:43 +02:00
2018-04-16 20:56:30 +02:00
2018-04-16 20:56:30 +02:00
2018-08-30 20:56:44 -04:00
2018-05-22 20:15:00 -04:00
2017-09-18 12:44:05 +02:00
2018-08-26 11:02:34 +03:00
2018-08-26 11:02:34 +03:00
2018-01-30 18:33:25 +01:00
2018-07-17 16:39:43 +02:00
2016-04-08 08:12:47 +03:00
2018-05-09 16:10:46 +01:00
2018-05-31 10:09:01 +01:00
2016-04-08 08:12:47 +03:00
2016-04-08 08:12:47 +03:00
2018-05-09 16:52:26 +01:00
2018-07-11 10:15:01 +01:00
2018-07-20 13:50:17 -07:00
2017-05-21 12:26:15 +03:00
2018-06-27 12:48:30 +02:00
2016-04-08 08:12:47 +03:00
2017-05-21 12:26:15 +03:00
2018-07-18 12:28:06 +01:00
2016-04-08 08:12:47 +03:00
2016-04-08 08:12:47 +03:00
2016-04-08 08:12:47 +03:00
2017-05-26 19:26:20 +03:00
2017-10-18 08:49:52 +02:00
2018-05-30 14:41:41 +02:00
2017-06-29 02:08:12 -03:00
2016-04-08 08:12:47 +03:00
2016-07-19 18:21:58 +03:00
2018-07-26 12:02:32 +01:00
2017-05-16 15:56:03 -04:00
2017-04-25 11:43:04 +02:00