[jboss-remoting-issues] [JBoss JIRA] Created: (JBREM-1108) Warn against making ConnectionValidator.validatorPingPeriod shorter than ConnectionValidator.validatorPingTimeout

Ron Sigal (JIRA) jira-events at lists.jboss.org
Tue Mar 3 23:58:22 EST 2009


Warn against making ConnectionValidator.validatorPingPeriod shorter than ConnectionValidator.validatorPingTimeout
-----------------------------------------------------------------------------------------------------------------

                 Key: JBREM-1108
                 URL: https://jira.jboss.org/jira/browse/JBREM-1108
             Project: JBoss Remoting
          Issue Type: Task
      Security Level: Public (Everyone can see)
    Affects Versions: 2.5.0.SP2 (Flounder) , 2.2.2.SP11
            Reporter: Ron Sigal
            Assignee: Ron Sigal
            Priority: Minor
             Fix For: 2.2.2.SP12, 2.5.0.SP3 (Flounder)


If the parameter org.jboss.remoting.ConnectionValidator.VALIDATOR_PING_PERIOD (actual value "validatorPingPeriod") is set to a value less than the value of ConnectionValidator.VALIDATOR_PING_TIMEOUT (actual value "validatorPingTimeout"), the connection validation process can fail.  ConnectionValidator.run() sets the variable isValid to false, sends a PING, and starts an instance of WaitOnConnectionCheckTimerTask.  If the PING invocation succeeds, run() sets isValid to true, and WaitOnConnectionCheckTimerTask quietly returns.  However, if the response to the PING invocation is delayed, and the ping timeout value is long enough, it is possible for ConnectionValidator.run() to set isValid to false and start a second WaitOnConnectionCheckTimerTask while the first WaitOnConnectionCheckTimerTask is still waiting.   Then, if the response to the first PING arrives, the first WaitOnConnectionCheckTimerTask will see that isValid is false and it will declare a connection failure.

There's no reason to start a new WaitOnConnectionCheckTimerTask while an existing WaitOnConnectionCheckTimerTask is still running.  The point is that validatorPingPeriod should be longer than validatorPingTimeout, so that, if a PING fails, there is time to notify any listeners of the failure and to shut down the ConnectionValidator before sending another PING.  

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-remoting-issues mailing list