Safe-threading and async HashMap

⚓ Rust    📅 2025-08-17    👤 surdeus    👁️ 20      

surdeus

Warning

This post was published 157 days ago. The information described in this article may have changed.

Hi!

I have such struct for example:

use tokio::sync::Mutex;
use create fxhash::FxHashMap;

struct StructWithState {
    state: Arc<Mutex<FxHashMap<String, String>>> // Or DashMap without Mutex
}

I have different mutation in async way further and both DashMap and Mutex + FxHashMap have deadlocks and other things.

Could you please give me some advice what is a better to use in such case?

3 posts - 3 participants

Read full topic

🏷️ Rust_feed