hashmap now has switchable thread safety