I tweaked a little with the source from BaseConnectionManager2 and instead of using the whole object as the key, I put it into the map with the toString() method.
i.e. instead of
this is not a solution but the lookup is succeeding now. However, this only exposes other areas in the code which fall victim to the same failing hashmap lookup.