dimitrov-adrian / directus-extension-searchsync

Simple Directus 9 extension that sync content with remote search engine.
MIT License
116 stars 27 forks source link

Reindexing collection is limited to 100 items #9

Closed benosman closed 3 years ago

benosman commented 3 years ago

Hello again,

On my site, I have reindexOnStart enabled, but i've noticed that the call to readByQuery only returns a maximum of 100 items. If you have more items than that in the collection, then some items will not be indexed.

The function either needs to remove the limit, or work in batches until complete.

dimitrov-adrian commented 3 years ago

Oh, yes, that because the internal limit.

I think batched will be best here, will take on it soon.

Also I hope https://github.com/directus/directus/pull/7675 taking place soon or by some shape, so cli command for reindexing will be good addition too.

dimitrov-adrian commented 3 years ago

It should be fixed now, thanks!