Author: kfujino
Date: Thu Feb  2 07:26:35 2017
New Revision: 1781351

URL: http://svn.apache.org/viewvc?rev=1781351&view=rev
Log:
Make the accessTimeout configurable in ClusterSingleSignOn.

Modified:
    
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/ClusterSingleSignOn.java
    
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/mbeans-descriptors.xml
    tomcat/tc8.0.x/trunk/webapps/docs/changelog.xml
    tomcat/tc8.0.x/trunk/webapps/docs/config/cluster-valve.xml

Modified: 
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/ClusterSingleSignOn.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/ClusterSingleSignOn.java?rev=1781351&r1=1781350&r2=1781351&view=diff
==============================================================================
--- 
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/ClusterSingleSignOn.java
 (original)
+++ 
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/ClusterSingleSignOn.java
 Thu Feb  2 07:26:35 2017
@@ -96,6 +96,14 @@ public class ClusterSingleSignOn extends
         this.terminateOnStartFailure = terminateOnStartFailure;
     }
 
+    private long accessTimeout = 5000;
+    public long getAccessTimeout() {
+        return accessTimeout;
+    }
+
+    public void setAccessTimeout(long accessTimeout) {
+        this.accessTimeout = accessTimeout;
+    }
 
     // ---------------------------------------------------- SingleSignOn 
Methods
 
@@ -164,6 +172,7 @@ public class ClusterSingleSignOn extends
                     this, cluster.getChannel(), rpcTimeout, 
cluster.getClusterName() + "-SSO-cache",
                     cls, terminateOnStartFailure);
             cache.setChannelSendOptions(mapSendOptions);
+            cache.setAccessTimeout(accessTimeout);
             this.cache = cache;
         } catch (Throwable t) {
             ExceptionUtils.handleThrowable(t);

Modified: 
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/mbeans-descriptors.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/mbeans-descriptors.xml?rev=1781351&r1=1781350&r2=1781351&view=diff
==============================================================================
--- 
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/mbeans-descriptors.xml
 (original)
+++ 
tomcat/tc8.0.x/trunk/java/org/apache/catalina/ha/authenticator/mbeans-descriptors.xml
 Thu Feb  2 07:26:35 2017
@@ -53,5 +53,9 @@
       name="terminateOnStartFailure"
       description="Flag for whether to terminate this map that failed to 
start."
       type="boolean"/>
+    <attribute
+      name="accessTimeout"
+      description="The timeout for a ping message in replication map."
+      type="long"/>
   </mbean>
 </mbeans-descriptors>

Modified: tomcat/tc8.0.x/trunk/webapps/docs/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc8.0.x/trunk/webapps/docs/changelog.xml?rev=1781351&r1=1781350&r2=1781351&view=diff
==============================================================================
--- tomcat/tc8.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc8.0.x/trunk/webapps/docs/changelog.xml Thu Feb  2 07:26:35 2017
@@ -63,6 +63,15 @@
       </add>
     </changelog>
   </subsection>
+  <subsection name="Cluster">
+    <changelog>
+      <add>
+        Make the <code>accessTimeout</code> configurable in
+        <code>ClusterSingleSignOn</code>. The <code>accessTimeout</code> is 
used
+        as a timeout period for PING in replication map. (kfujino)
+      </add>
+    </changelog>
+  </subsection>
   <subsection name="WebSocket">
     <changelog>
       <fix>

Modified: tomcat/tc8.0.x/trunk/webapps/docs/config/cluster-valve.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc8.0.x/trunk/webapps/docs/config/cluster-valve.xml?rev=1781351&r1=1781350&r2=1781351&view=diff
==============================================================================
--- tomcat/tc8.0.x/trunk/webapps/docs/config/cluster-valve.xml (original)
+++ tomcat/tc8.0.x/trunk/webapps/docs/config/cluster-valve.xml Thu Feb  2 
07:26:35 2017
@@ -156,6 +156,11 @@
         part of the heartbeat process. If not specified, the default value of
         <code>false</code> is used.</p>
       </attribute>
+      <attribute name="accessTimeout" required="false">
+        The timeout for a ping message. If a remote map does not respond within
+        this timeout period, its regarded as disappeared.
+        Default value is <code>5000</code> milliseconds.
+      </attribute>
     </attributes>
   </subsection>
 </section>



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

Reply via email to