hawq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From w...@apache.org
Subject incubator-hawq git commit: HAWQ-912. Skip temporary Directories checking for master/standby
Date Tue, 12 Jul 2016 02:14:03 GMT
Repository: incubator-hawq
Updated Branches:
  refs/heads/master c5a3f42fd -> 3618fe16c


HAWQ-912. Skip temporary Directories checking for master/standby


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

Branch: refs/heads/master
Commit: 3618fe16ca17d0fd77329e15416002ab831a5b19
Parents: c5a3f42
Author: Wen Lin <wlin@pivotal.io>
Authored: Tue Jul 12 10:13:30 2016 +0800
Committer: Wen Lin <wlin@pivotal.io>
Committed: Tue Jul 12 10:13:30 2016 +0800

----------------------------------------------------------------------
 src/backend/resourcemanager/resourcemanager.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/3618fe16/src/backend/resourcemanager/resourcemanager.c
----------------------------------------------------------------------
diff --git a/src/backend/resourcemanager/resourcemanager.c b/src/backend/resourcemanager/resourcemanager.c
index e511b97..96cf9ff 100644
--- a/src/backend/resourcemanager/resourcemanager.c
+++ b/src/backend/resourcemanager/resourcemanager.c
@@ -1048,14 +1048,17 @@ int  loadDynamicResourceManagerConfigure(void)
 				 DRMGlobalInstance->SegmentMemoryMB,
 				 DRMGlobalInstance->SegmentCore);
 
-    // For temporary directories
-    InitTemporaryDirs(&DRMGlobalInstance->LocalHostTempDirectories, rm_seg_tmp_dirs);
+	if ( DRMGlobalInstance->Role == START_RM_ROLE_SEGMENT )
+	{
+		// For temporary directories
+		InitTemporaryDirs(&DRMGlobalInstance->LocalHostTempDirectories, rm_seg_tmp_dirs);
 
-	DQUEUE_LOOP_BEGIN(&DRMGlobalInstance->LocalHostTempDirectories, iter, SimpStringPtr,
value)
-		elog(LOG, "HAWQ Segment RM :: Temporary directory %s", value->Str);
-	DQUEUE_LOOP_END
+		DQUEUE_LOOP_BEGIN(&DRMGlobalInstance->LocalHostTempDirectories, iter, SimpStringPtr,
value)
+			elog(LOG, "HAWQ Segment RM :: Temporary directory %s", value->Str);
+		DQUEUE_LOOP_END
 
-	checkAndBuildFailedTmpDirList();
+		checkAndBuildFailedTmpDirList();
+	}
 
 	/****** Resource enforcement GUCs begins ******/
 


Mime
View raw message