hawq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From iw...@apache.org
Subject incubator-hawq git commit: check null cond for explain analyse
Date Mon, 07 Mar 2016 07:04:03 GMT
Repository: incubator-hawq
Updated Branches:
  refs/heads/master 17181fbe1 -> 0bf50ef93


check null cond for explain analyse


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

Branch: refs/heads/master
Commit: 0bf50ef93ffcbf6fd44abd1966bcd21c8b993526
Parents: 17181fb
Author: ivan <iweng@pivotal.io>
Authored: Mon Mar 7 14:51:18 2016 +0800
Committer: ivan <iweng@pivotal.io>
Committed: Mon Mar 7 14:51:18 2016 +0800

----------------------------------------------------------------------
 src/backend/cdb/cdbexplain.c       | 6 +++---
 src/backend/cdb/cdbmetadatacache.c | 8 ++++++--
 2 files changed, 9 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/0bf50ef9/src/backend/cdb/cdbexplain.c
----------------------------------------------------------------------
diff --git a/src/backend/cdb/cdbexplain.c b/src/backend/cdb/cdbexplain.c
index cb3f55e..7985d68 100644
--- a/src/backend/cdb/cdbexplain.c
+++ b/src/backend/cdb/cdbexplain.c
@@ -1147,8 +1147,8 @@ cdbexplain_depositStatsToNode(PlanState *planstate, CdbExplain_RecvStatCtx
*ctx)
       instr->firsttuple       = ntuples.nsimax->firsttuple;
       instr->startup          = ntuples.nsimax->startup;
       instr->total            = ntuples.nsimax->total;
-      instr->startupLast      = ntuples.nsiLast->startup;
-      instr->totalLast        = ntuples.nsiLast->total;
+      instr->startupLast      = ntuples.nsiLast ? ntuples.nsiLast->startup : ntuples.nsimax->startup;
+      instr->totalLast        = ntuples.nsiLast ? ntuples.nsiLast->total : ntuples.nsimax->total;
       instr->ntuples          = ntuples.nsimax->ntuples;
       instr->nloops           = ntuples.nsimax->nloops;
       instr->execmemused      = ntuples.nsimax->execmemused;
@@ -1157,7 +1157,7 @@ cdbexplain_depositStatsToNode(PlanState *planstate, CdbExplain_RecvStatCtx
*ctx)
       instr->workfileReused   = ntuples.nsimax->workfileReused;
       instr->workfileCreated  = ntuples.nsimax->workfileCreated;
       instr->firststart       = ntuples.nsimax->firststart;
-      instr->firststartLast       = ntuples.nsiLast->firststart;
+      instr->firststartLast       = ntuples.nsiLast ? ntuples.nsiLast->firststart :
ntuples.nsimax->firststart;
     }
 
     /* Save extra message text for the most interesting winning qExecs. */

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/0bf50ef9/src/backend/cdb/cdbmetadatacache.c
----------------------------------------------------------------------
diff --git a/src/backend/cdb/cdbmetadatacache.c b/src/backend/cdb/cdbmetadatacache.c
index 74f4869..08fd618 100644
--- a/src/backend/cdb/cdbmetadatacache.c
+++ b/src/backend/cdb/cdbmetadatacache.c
@@ -163,13 +163,13 @@ static HTAB                     *RevertBlockNamesMap = NULL;
 static HTAB                     *RevertBlockTopologyPathsMap = NULL;
 
 //static BlockLocation *CreateHdfsFileBlockLocations(BlockLocation *hdfs_locations, int block_num);
-static BlockLocation *MergeHdfsFileBlockLocations(BlockLocation *locations1, int block_num1,
BlockLocation *locations2, int block_num2);
+//static BlockLocation *MergeHdfsFileBlockLocations(BlockLocation *locations1, int block_num1,
BlockLocation *locations2, int block_num2);
 
 
 // create block locations for user
 static BlockLocation *GetHdfsFileBlockLocationsNoCache(const HdfsFileInfo *file_info, uint64_t
filesize, int *block_num);
 static BlockLocation *GetHdfsFileBlockLocationsFromCache(MetadataCacheEntry *entry, uint64_t
filesize, int *block_num);
-static BlockLocation *AppendHdfsFileBlockLocationsToCache(const HdfsFileInfo *file_info,
MetadataCacheEntry *entry, uint64_t filesize, int *block_num, double *hit_ratio);
+//static BlockLocation *AppendHdfsFileBlockLocationsToCache(const HdfsFileInfo *file_info,
MetadataCacheEntry *entry, uint64_t filesize, int *block_num, double *hit_ratio);
 
 /*
  *  Estimate metadata cache shared memory size
@@ -895,6 +895,7 @@ err:
 /*
  *  Get hdfs block locations from cache and fetch extra part from hadoop hdfs
  */
+/*
 BlockLocation *
 AppendHdfsFileBlockLocationsToCache(const HdfsFileInfo *file_info, MetadataCacheEntry *entry,
uint64_t filesize, int *block_num, double *hit_ratio)
 {
@@ -1028,6 +1029,7 @@ done:
 
     return locations;
 }
+*/
 
 /*
  * Free hdf file block location which create from GetHdfsFileBlockLocations
@@ -1117,6 +1119,7 @@ CreateHdfsFileBlockLocations(BlockLocation *hdfs_locations, int block_num)
     return locations;
 }
 
+/*
 BlockLocation *
 MergeHdfsFileBlockLocations(BlockLocation *locations1, int block_num1, BlockLocation *locations2,
int block_num2)
 {
@@ -1164,6 +1167,7 @@ MergeHdfsFileBlockLocations(BlockLocation *locations1, int block_num1,
BlockLoca
     return locations;
 
 }
+*/
 
 void 
 DumpHdfsFileBlockLocations(BlockLocation *locations, int block_num)


Mime
View raw message