tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Hanik - Dev Lists <devli...@hanik.com>
Subject Re: svn commit: r668249 - /tomcat/trunk/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java
Date Tue, 17 Jun 2008 16:49:47 GMT
my initial reaction is a -1 to this one

it should be

if ( entry != null && entry.isPrimary() ) set.add(new 
MapEntry(key,entry.getValue()));

and not propagate internals of the cluster information out to the caller


Filip


markt@apache.org wrote:
> Author: markt
> Date: Mon Jun 16 10:22:36 2008
> New Revision: 668249
>
> URL: http://svn.apache.org/viewvc?rev=668249&view=rev
> Log:
> Fix 	
> Map.entrySet() should return entries, not values
>
> Modified:
>     tomcat/trunk/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java
>
> Modified: tomcat/trunk/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java?rev=668249&r1=668248&r2=668249&view=diff
> ==============================================================================
> --- tomcat/trunk/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java (original)
> +++ tomcat/trunk/java/org/apache/catalina/tribes/tipis/AbstractReplicatedMap.java Mon
Jun 16 10:22:36 2008
> @@ -1017,7 +1017,7 @@
>                  Map.Entry e = (Map.Entry)i.next();
>                  Object key = e.getKey();
>                  MapEntry entry = (MapEntry)super.get(key);
> -                if ( entry != null && entry.isPrimary() ) set.add(entry.getValue());
> +                if ( entry != null && entry.isPrimary() ) set.add(entry);
>              }
>              return Collections.unmodifiableSet(set);
>          }
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: dev-help@tomcat.apache.org
>
>
>
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message