Fixed issues with Entity hashCode/equals - it was not using entity type.
Removes ThreadLocal from JStopWatch.
Clean thread local on removal of last transaction