Use a concurrent hashmap to avoid deadlocks