Skip to content

Commit 95ce78f

Browse files
Merge #351
351: Clear manager in the import loop (console command) r=norkunas a=johndodev Calling $manager->clear() in the import loop to avoid memory problems. # Pull Request ## Related issue Fixes #350 ## What does this PR do? - Add a call of $manager->clear() in the import loop to avoir memory problems. ## PR checklist Please check if your PR fulfills the following requirements: - [x] Does this PR fix an existing issue, or have you listed the changes applied in the PR description (and why they are needed)? - [x] Have you read the contributing guidelines? - [x] Have you made sure that the title is accurate and descriptive of the changes? Co-authored-by: Jonathan Plantey <[email protected]>
2 parents d3d3f97 + 6ea7d69 commit 95ce78f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/Command/MeilisearchImportCommand.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,8 @@ protected function execute(InputInterface $input, OutputInterface $output): int
141141
);
142142
}
143143

144+
$manager->clear();
145+
144146
++$page;
145147
} while (\count($entities) >= $batchSize);
146148

0 commit comments

Comments
 (0)