tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Keiichi Fujino <>
Subject Re: svn commit: r996778 - in /tomcat/trunk: java/org/apache/catalina/ha/session/ java/org/apache/catalina/tribes/tipis/ webapps/docs/changelog.xml
Date Wed, 15 Sep 2010 05:22:57 GMT
>> URL:
>> Log:
>> Fix
>> When non-primary node changes into a primary node, make sure isPrimarySession is
changed to true.
>> Modified:
>>    tomcat/trunk/java/org/apache/catalina/ha/session/
>>    tomcat/trunk/java/org/apache/catalina/tribes/tipis/
> I may be wrong, but the change to this file appears to be nothing to
> do with the SVN log message.
> Looks like a separate change was accidentally committed.

When a primary node is stopped, it becomes the following.

sessionA(Primary node=Tomcat1, Backup node=Tomcat2, Proxy node=Tomcat3)
Tomcat1 DeltaSession#isPrimarySession:true
Tomcat2 DeltaSession#isPrimarySession:false
Tomcat3 is Proxy.

Tomcat1 stopped.

sessionA(Primary node=Tomcat2, Backup node=Tomcat3, Proxy node=no node)
Tomcat2 DeltaSession#isPrimarySession:false
Tomcat3 DeltaSession#isPrimarySession:false

DeltaSession#isPrimarySession is false though the node changes from
the backup into primary.
We should change isPrimarySession to true.

I did the following corrections to this problem.
Because after the backup node is promoted to a primary node,
MapOwner#objectMadePrimay is called,
I added "setPrimarySession(true)" to
MapOwner(BackupManager)#objectMadePrimay method.
As a result, DeltaSession#isPrimarySession of Tomcat2 is changed to true.

I added "getMapOwner().objectMadePrimay(key, entry.getValue());" to
so that when we get a non-primary session, isPrimarySession change to true.

I think that isPrimarySession is changed to true in this rev.
Where of this rev is the problem?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message