[ https://jira.terracotta.org/jira//browse/CDV-277?page=comments#action_21161 ] Steven Harris commented on CDV-277: -----------------------------------
You did the right stuff. I would have tried making it a root too. We'll see what we can come up with on this. > Sharing java.util.Currency objects breaks equality > -------------------------------------------------- > > Key: CDV-277 > URL: https://jira.terracotta.org/jira//browse/CDV-277 > Project: Community Development > Issue Type: Bug > Reporter: Anders Bengtsson > Assigned To: Antonio Si > > When I mix java.util.Currency instances that come from the shared environment > with those created locally, equals() returns false for identical currencies. > java.util.Currency doesn't override equals() from java.lang.Object, so it's > using object identities to compare instances. > I believe this instance cache, in Currency, would need to be shared for > Currency to work correctly: > private static HashMap instances = new HashMap(7); > Another option would be to modify the behavior of the equals() method on > Currency. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: https://jira.terracotta.org/jira//secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira _______________________________________________ tc-dev mailing list [email protected] http://lists.terracotta.org/mailman/listinfo/tc-dev
