implemented iter, iter_mut, keys, values and values_mut.#17
implemented iter, iter_mut, keys, values and values_mut.#17Levyks wants to merge 1 commit intowillothy:mainfrom
iter, iter_mut, keys, values and values_mut.#17Conversation
|
Thanks for the PR! At a glance I'm concerned by the fact that we have to get read locks on all shards at once. Since the method is async anyways, maybe it would be better to use the Stream API and have each iteration return a future? That way we can still have concurrent writes to shards that aren't actively being iterated over. |
Yeah, that was one option that I considered, I haven't had the time yet this week, but I will implement a stream iterable as soon as possible |
|
Thank you, I appreciate it! No rush :) |
|
hi! I found that entry and iter APIs are impl-ed already buy not merged. I wonder what happend and can I use these unmerged features anyway? |
Solves #11
I don't thinks this is possible without
unsafe, but since the crate already uses it elsewhere, I think it's fine!?!The performance of this will be poor, but I think it's still better than not giving access to the items at all.