Github user trinakrug commented on a diff in the pull request:

    https://github.com/apache/incubator-trafodion/pull/958#discussion_r102274683
  
    --- Diff: core/sqf/monitor/linux/zclient.cxx ---
    @@ -472,6 +469,65 @@ void CZClient::CheckCluster( void )
         TRACE_EXIT;
     }
     
    +void CZClient::CheckMyZNode( void )
    +{
    +    const char method_name[] = "CZClient::CheckMyZNode";
    +    TRACE_ENTRY;
    +
    +    int zerr;
    +    struct timespec currentTime;
    +
    +    if ( IsCheckCluster() )
    +    {
    +        if (resetMyZNodeFailedTime_)
    +        {
    +            resetMyZNodeFailedTime_ = false;
    +            clock_gettime(CLOCK_REALTIME, &myZNodeFailedTime_);
    +            myZNodeFailedTime_.tv_sec += (GetSessionTimeout() * 2);
    +            if (trace_settings & (TRACE_INIT | TRACE_RECOVERY))
    +            {
    +                trace_printf( "%s@%d" " - Resetting MyZnode Fail Time 
%ld(secs)\n"
    +                            , method_name, __LINE__
    +                            , myZNodeFailedTime_.tv_sec );
    +            }
    +        }
    +        if ( ! IsZNodeExpired( Node_name, zerr ) )
    +        {
    +            if ( zerr == ZCONNECTIONLOSS || zerr == ZOPERATIONTIMEOUT )
    +            {
    +                // Ignore transient errors with the quorum.
    +                // However, if longer than the session
    +                // timeout, handle it as a hard error.
    +                clock_gettime(CLOCK_REALTIME, &currentTime);
    +                if (currentTime.tv_sec > myZNodeFailedTime_.tv_sec)
    --- End diff --
    
    If resetMyZNodeFailedTime_ is true, then this if statement will always 
evaluate to true.   Just verifying that is the desired outcome.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to