Skip to content

Commit

Permalink
HPCC-32031 Generate summary information in workunit to speed up file …
Browse files Browse the repository at this point in the history
…list operations

Further changes following review

Signed-off-by: Richard Chapman <[email protected]>
  • Loading branch information
richardkchapman committed Jun 26, 2024
1 parent e587736 commit b6df4c9
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 7 deletions.
1 change: 0 additions & 1 deletion common/pkgfiles/referencedfilelist.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -968,7 +968,6 @@ bool ReferencedFileList::addFilesFromQuery(IConstWorkUnit *cw, const IHpccPackag
SummaryMap files;
if (cw->getSummary(SummaryType::ReadFile, files) &&
cw->getSummary(SummaryType::ReadIndex, files))
// MORE - should this also include ReadPersist?
{
for (const auto& [lName, isOpt] : files)
{
Expand Down
3 changes: 1 addition & 2 deletions common/workunit/workunit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8731,10 +8731,9 @@ static const char *summaryTypeName(SummaryType type)
{
case SummaryType::ReadFile: return "ReadFile";
case SummaryType::ReadIndex: return "ReadIndex";
case SummaryType::ReadPersist: return "ReadPersist";
case SummaryType::WriteFile: return "WriteFile";
case SummaryType::WriteIndex: return "WriteIndex";
case SummaryType::WritePersist: return "WritePersist";
case SummaryType::PersistFile: return "PersistFile";
case SummaryType::SpillFile: return "SpillFile";
case SummaryType::JobTemp: return "JobTemp";
case SummaryType::Service: return "Service";
Expand Down
3 changes: 1 addition & 2 deletions common/workunit/workunit.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1187,10 +1187,9 @@ enum class SummaryType
First,
ReadFile = First,
ReadIndex,
ReadPersist,
WriteFile,
WriteIndex,
WritePersist,
PersistFile,
SpillFile,
JobTemp,
Service,
Expand Down
2 changes: 1 addition & 1 deletion ecl/hqlcpp/hqlhtcpp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10983,7 +10983,7 @@ ABoundActivity * HqlCppTranslator::doBuildActivityOutput(BuildCtx & ctx, IHqlExp
if (expr->hasAttribute(jobTempAtom))
summaryType = SummaryType::JobTemp;
else if (expr->hasAttribute(_workflowPersist_Atom))
summaryType = SummaryType::WritePersist;
summaryType = SummaryType::PersistFile;

bool useImplementationClass = options.minimizeActivityClasses && targetRoxie() && expr->hasAttribute(_spill_Atom);
Owned<ActivityInstance> instance = new ActivityInstance(*this, ctx, kind, expr, activityArgName);
Expand Down
2 changes: 1 addition & 1 deletion ecl/hqlcpp/hqlsource.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1191,7 +1191,7 @@ void SourceBuilder::buildFilenameMember()
if (tableExpr->hasAttribute(jobTempAtom))
summaryType = SummaryType::JobTemp;
else if (tableExpr->hasAttribute(_workflowPersist_Atom))
summaryType = SummaryType::ReadPersist;
summaryType = SummaryType::PersistFile;
translator.buildFilenameFunction(*instance, instance->startctx, WaFilename, "getFileName", nameExpr, translator.hasDynamicFilename(tableExpr), summaryType, tableExpr->hasAttribute(optAtom));
}

Expand Down

0 comments on commit b6df4c9

Please sign in to comment.