Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a configuration setting on indices to choose a custom repository method to use in "meilisearch:import" command #344

Open
remigarcia opened this issue Aug 9, 2024 · 0 comments · May be fixed by #345

Comments

@remigarcia
Copy link
Contributor

Description
The Meilisearch\Bundle\Command\MeilisearchImportCommand command (meilisearch:import) uses the findBy method by default on the repository of the entities to index. There is no possibility to pass parameters to this command to filter entities prior to querying them in Doctrine.

Basic example
In my specific case, I have hundreds of thousands entities in my database, but only 5% of them should be indexed.
A full indexation with meilisearch:import command is very long in my case, as it gets all the unfiltered entites, and checks the index_if method on each to know if it needs to be indexed or not.
When I fill a new index with my data, I want to use a custom method in the entity repository to retrieve only the entities that will need to be indexed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant