lock access to TM.endpointToHostIdMap
patch by Mikhail Stepura; reviewed by jbellis for CASSANDRA-6103
cleanup
merge from 1.2