Skip to content

Commit e91c2e0

Browse files
committed
TASK: Better output on workspace indexing
1 parent b0ada14 commit e91c2e0

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

Classes/Flowpack/ElasticSearch/ContentRepositoryQueueIndexer/Command/NodeIndexQueueCommandController.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,8 @@ protected function outputSystemReport()
128128
*/
129129
protected function indexWorkspace($workspaceName, $indexPostfix)
130130
{
131+
$this->outputLine('<info>++</info> Indexing %s workspace', [$workspaceName]);
132+
$nodeCounter = 0;
131133
$offset = 0;
132134
$batchSize = 250;
133135
while (true) {
@@ -140,19 +142,22 @@ protected function indexWorkspace($workspaceName, $indexPostfix)
140142
'nodeIdentifier' => $data['nodeIdentifier'],
141143
'dimensions' => $data['dimensions']
142144
];
145+
$nodeCounter++;
143146
}
144147

145148
if ($jobData === []) {
146149
break;
147150
}
148151

149152
$indexingJob = new IndexingJob($indexPostfix, $workspaceName, $jobData);
150-
$this->jobManager->queue('Flowpack.ElasticSearch.ContentRepositoryQueueIndexer', $indexingJob);
153+
$this->jobManager->queue(self::QUEUE_NAME, $indexingJob);
151154
$this->output('.');
152155
$offset += $batchSize;
153156
$this->persistenceManager->clearState();
154157
}
155158
$this->outputLine();
159+
$this->outputLine("\nNumber of Nodes be indexed in workspace '%s': %d", [$workspaceName, $nodeCounter]);
160+
$this->outputLine();
156161
}
157162

158163
/**

0 commit comments

Comments
 (0)