Use copying of map views to achieve locking as foreach is an alternative