trafodion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dbirds...@apache.org
Subject [1/2] incubator-trafodion git commit: [TRAFODION-1980] Fixed node 'up' behavior when physical non-existent
Date Wed, 11 May 2016 16:02:01 GMT
Repository: incubator-trafodion
Updated Branches:
  refs/heads/master cdd1bef06 -> f05875519


[TRAFODION-1980] Fixed node 'up' behavior when physical non-existent


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/acf20663
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/acf20663
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/acf20663

Branch: refs/heads/master
Commit: acf206633cd876b6ca55e6e01abcc81240bb13dc
Parents: aea7615
Author: Zalo Correa <zalo.correa@esgyn.com>
Authored: Tue May 10 08:39:59 2016 -0700
Committer: Zalo Correa <zalo.correa@esgyn.com>
Committed: Tue May 10 08:47:36 2016 -0700

----------------------------------------------------------------------
 core/sqf/monitor/linux/shell.cxx | 30 +++---------------------------
 1 file changed, 3 insertions(+), 27 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/acf20663/core/sqf/monitor/linux/shell.cxx
----------------------------------------------------------------------
diff --git a/core/sqf/monitor/linux/shell.cxx b/core/sqf/monitor/linux/shell.cxx
index c30f1da..03a911c 100755
--- a/core/sqf/monitor/linux/shell.cxx
+++ b/core/sqf/monitor/linux/shell.cxx
@@ -183,33 +183,9 @@ bool init_pnode_map( void )
     pnodeConfig = ClusterConfig.GetFirstPNodeConfig();
     for ( ; pnodeConfig; pnodeConfig = pnodeConfig->GetNext() )
     {
-        // TEST_POINT and exclude list : to force state down on node name
-         NodeState_t nodeState = StateUp;
-         const char *downNodeName = getenv( TP001_NODE_DOWN );
-         const char *downNodeList = getenv( TRAF_EXCLUDE_LIST );
-	 string downNodeString = " ";
-	 if (downNodeList)
-	 {
-	   downNodeString += downNodeList;
-	   downNodeString += " ";
-	 }
-	 string downNodeToFind = " ";
-	 downNodeToFind += pnodeConfig->GetName();
-	 downNodeToFind += " ";
-         if (((downNodeList != NULL) && 
-	    (strstr(downNodeString.c_str(),downNodeToFind.c_str()))) ||
-            ( downNodeName != NULL && 
-             !strcmp( downNodeName, pnodeConfig->GetName() ) ))
-         {
-             nodeState = StateDown;
-         }
-
-        // effectively remove spare nodes on startup only
-        if ( SpareNodeColdStandby && pnodeConfig->IsSpareNode() )
-        {
-            nodeState = StateDown;
-        }
-
+        // Set initial state of all physical nodes in a real cluster to StateDown
+        // update_cluster_state() will set operational state of physical node
+        NodeState_t nodeState = StateDown;
         physicalNode = new CPhysicalNode( pnodeConfig->GetName(), nodeState );
         if ( physicalNode )
         {


Mime
View raw message