Fix bugs in equals and hashCode
Merge pull request #1063 from zsxwing/Timestamped-bug

Fix bugs in equals and hashCode of Timestamped