Only fire RosterListener#entriesUpdated for RosterEntries that changed
Description
The RosterPacketListener adds roster entries to the list of updated entries without checking if the entry actually changed. This causes unnecessary notifications to the RosterListeners although there is no new information available for an entry.
The attached patch fixes this bug by implementeng a new #equalsDeep() method for RosterEntry which determines equality using all members of the RosterEntry class. The RosterPacketListener now only adds the entry to the updated entries if #equalsDeep() compared with the old entry returns false.
the "deepquals" method of the RosterEntry doesn't seem to work properly. when the name is changed deepmethod says that the classes are equals even though they have different names!
Walter Ebeling March 8, 2011 at 5:13 PM
Roll back to a version prior the check in of this change allows a rename of groups
The RosterPacketListener adds roster entries to the list of updated entries without checking if the entry actually changed. This causes unnecessary notifications to the RosterListeners although there is no new information available for an entry.
The attached patch fixes this bug by implementeng a new #equalsDeep() method for RosterEntry which determines equality using all members of the RosterEntry class.
The RosterPacketListener now only adds the entry to the updated entries if #equalsDeep() compared with the old entry returns false.