Browse Source

HPCC-10106 Rebuild Persists if input files change, ignore other persists

Previously persists rebuild if any direct input files, or any persists they
were dependent on changed.  With this change the persist will rebuild if any
direct or indirect input files change.  This allows intermediate persists
to be deleted without causing other persists to rebuild.

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>
Gavin Halliday 11 years ago
parent
commit
afbe461a23
4 changed files with 7 additions and 0 deletions
  1. 1 0
      ecl/hqlcpp/hqlcpp.cpp
  2. 1 0
      ecl/hqlcpp/hqlcpp.ipp
  3. 4 0
      ecl/hqlcpp/hqlttcpp.cpp
  4. 1 0
      ecl/hqlcpp/hqlttcpp.ipp

+ 1 - 0
ecl/hqlcpp/hqlcpp.cpp

@@ -1706,6 +1706,7 @@ void HqlCppTranslator::cacheOptions()
         DebugOption(options.traceIR,"traceIR",false),
         DebugOption(options.preserveCaseExternalParameter,"preserveCaseExternalParameter",true),
         DebugOption(options.optimizeParentAccess,"optimizeParentAccess",false),
+        DebugOption(options.expandPersistInputDependencies,"expandPersistInputDependencies",true),
     };
 
     //get options values from workunit

+ 1 - 0
ecl/hqlcpp/hqlcpp.ipp

@@ -721,6 +721,7 @@ struct HqlCppOptions
     bool                traceIR;
     bool                preserveCaseExternalParameter;
     bool                optimizeParentAccess;
+    bool                expandPersistInputDependencies;
 };
 
 //Any information gathered while processing the query should be moved into here, rather than cluttering up the translator class

+ 4 - 0
ecl/hqlcpp/hqlttcpp.cpp

@@ -5255,6 +5255,7 @@ WorkflowTransformer::WorkflowTransformer(IWorkUnit * _wu, HqlCppTranslator & _tr
     onceWfid = 0;
     combineAllStored = translator.queryOptions().combineAllStored;
     combineTrivialStored = translator.queryOptions().combineTrivialStored;
+    expandPersistInputDependencies = translator.queryOptions().expandPersistInputDependencies;
     isRootAction = true;
     isRoxie = (translator.getTargetClusterType() == RoxieCluster);
     workflowOut = NULL;
@@ -5417,6 +5418,9 @@ void WorkflowTransformer::extractDependentInputs(UnsignedArray & visited, Depend
         switch (match->workflowOp)
         {
         case no_persist:
+            if (expandPersistInputDependencies)
+                break;
+            continue;
         case no_stored:
             continue;
         }

+ 1 - 0
ecl/hqlcpp/hqlttcpp.ipp

@@ -533,6 +533,7 @@ protected:
     bool                      combineTrivialStored;
     bool                      isRootAction;
     bool                      isRoxie;
+    bool                      expandPersistInputDependencies;
     UnsignedArray             cumulativeDependencies;
     UnsignedArray             emptyDependencies;
     UnsignedArray             storedWfids;