tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Keiichi Fujino <kfuj...@apache.org>
Subject Re: svn commit: r1039051 - in /tomcat/trunk: java/org/apache/catalina/ha/session/DeltaManager.java webapps/docs/changelog.xml
Date Wed, 01 Dec 2010 02:41:02 GMT
IMHO,
In current cluster membership implementation, local member is not
included in the cluster members list.
"cluster.getMembers().length" returns members that doesn't contain
local member.

Therefore, in this rev,
getAllClusterSessions does not work correctly when two tomcats
clustering configuration.

-- 
Keiichi.Fujino

12:24 2010
> New Revision: 1039051
>
> URL: http://svn.apache.org/viewvc?rev=1039051&view=rev
> Log:
> Fix a couple of clustering issues:
>  - Don't try and obtain session data from the cluster if the current node is the only
node in the cluster.
>  - Log requesting session data as INFO rather than WARNING.
>
> Modified:
>    tomcat/trunk/java/org/apache/catalina/ha/session/DeltaManager.java
>    tomcat/trunk/webapps/docs/changelog.xml
>
> Modified: tomcat/trunk/java/org/apache/catalina/ha/session/DeltaManager.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/ha/session/DeltaManager.java?rev=1039051&r1=1039050&r2=1039051&view=diff
> ==============================================================================
> --- tomcat/trunk/java/org/apache/catalina/ha/session/DeltaManager.java (original)
> +++ tomcat/trunk/java/org/apache/catalina/ha/session/DeltaManager.java Thu Nov 25 14:12:24
2010
> @@ -802,7 +802,7 @@ public CatalinaCluster getCluster() {
>      * @see #findSessionMasterMember()
>      */
>     public synchronized void getAllClusterSessions() {
> -        if (cluster != null && cluster.getMembers().length > 0) {
> +        if (cluster != null && cluster.getMembers().length > 1) {
>             long beforeSendTime = System.currentTimeMillis();
>             Member mbr = findSessionMasterMember();
>             if(mbr == null) { // No domain member found
> @@ -820,8 +820,8 @@ public CatalinaCluster getCluster() {
>                      receiverQueue = true ;
>                 }
>                 cluster.send(msg, mbr);
> -                if (log.isWarnEnabled())
> -                    log.warn(sm.getString("deltaManager.waitForSessionState",getName(),
mbr, Integer.valueOf(getStateTransferTimeout())));
> +                if (log.isInfoEnabled())
> +                    log.info(sm.getString("deltaManager.waitForSessionState",getName(),
mbr, Integer.valueOf(getStateTransferTimeout())));
>                 // FIXME At sender ack mode this method check only the state
transfer and resend is a problem!
>                 waitForSendAllSessions(beforeSendTime);
>             } finally {
>
> Modified: tomcat/trunk/webapps/docs/changelog.xml
> URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1039051&r1=1039050&r2=1039051&view=diff
> ==============================================================================
> --- tomcat/trunk/webapps/docs/changelog.xml (original)
> +++ tomcat/trunk/webapps/docs/changelog.xml Thu Nov 25 14:12:24 2010
> @@ -70,6 +70,11 @@
>         <bug>50185</bug>: Add additional trace level logging to Tribes
to assist
>         with fault diagnosis. Based on a patch by Ariel. (markt)
>       </add>
> +      <fix>
> +        Don&apos;t try and obtain session data from the cluster if the current
> +        node is the only node in the cluster. Log requesting session data as
> +        INFO rather than WARNING. (markt)
> +      </fix>
>     </changelog>
>   </subsection>
>   <subsection name="Web applications">
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: dev-help@tomcat.apache.org
>
>



-- 
Keiichi.Fujino

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


Mime
View raw message