浏览代码

Merge pull request #10817 from ghalliday/issue18757

HPCC-18757 Annotate read and write to persist files in graph label

Reviewed-By: Jake Smith <jake.smith@lexisnexis.com>
Reviewed-By: Richard Chapman <rchapman@hpccsystems.com>
Richard Chapman 7 年之前
父节点
当前提交
031eec55c3
共有 2 个文件被更改,包括 14 次插入4 次删除
  1. 8 2
      ecl/hqlcpp/hqlhtcpp.cpp
  2. 6 2
      ecl/hqlcpp/hqlsource.cpp

+ 8 - 2
ecl/hqlcpp/hqlhtcpp.cpp

@@ -10576,10 +10576,16 @@ ABoundActivity * HqlCppTranslator::doBuildActivityOutput(BuildCtx & ctx, IHqlExp
     {
         StringBuffer s;
         s.append(getActivityText(kind));
+        s.append("\n");
         if (expr->hasAttribute(_spill_Atom))
-            s.append("\nSpill File");
+            s.append("Spill File");
         else
-            filename->toString(s.append("\n"));
+        {
+            if (expr->hasAttribute(_workflowPersist_Atom))
+                s.append("Persist ");
+
+            filename->toString(s);
+        }
         instance->graphLabel.set(s.str());
     }
 

+ 6 - 2
ecl/hqlcpp/hqlsource.cpp

@@ -1943,6 +1943,10 @@ ABoundActivity * SourceBuilder::buildActivity(BuildCtx & ctx, IHqlExpression * e
             graphLabel.append("\nSpill");
         else
         {
+            graphLabel.newline();
+            if (tableExpr->hasAttribute(_workflowPersist_Atom))
+                graphLabel.append("Persist ");
+
             StringBuffer filename;
             //Call getStringValue() rather than generateECL() to avoid 't quote \ etc. in the string
             getStringValue(filename.append("'"), nameExpr).append("'");
@@ -1957,10 +1961,10 @@ ABoundActivity * SourceBuilder::buildActivity(BuildCtx & ctx, IHqlExpression * e
                         break;
                     coloncolon = next;
                 }
-                graphLabel.newline().append("'...").append(coloncolon);
+                graphLabel.append("'...").append(coloncolon);
             }
             else
-                graphLabel.newline().append(filename);
+                graphLabel.append(filename);
         }
     }
     instance->graphLabel.set(graphLabel.str());