Closed maiconkf closed 11 months ago
Can you provide step by step details when it works and when it doesn't work?
This just happened with me too.
my collection path: 'customers/{uid}/referreds' documents getting indexed from 'customers/{uid}/imports/{importid}/referreds'
I still didn't notice if it happens with new records but with existing it surely do.
This is also happening to me now (didn't seem to in older versions).
My collection path is organisations/{orgId}/users
which is also indexing the root collection users
which is then overwriting the correct collection objects.
EDIT: This could actually be a bug with the initial filling of the collection using the Full Index existing documents?
feature set to TRUE
unfortunately there is no api available to target a sub-collection. in order to support sub-collections indexing, Firebase team recommended I use the collectionGroup api which grabs all collections with the collection name, e.g. users
. if Firebase team enables better targeting of subcollections, i will implement it. for now, i am closing this since there is not an approach to resolve this issue.
Taking a look through the full indexing feature - it does appear that the collectionGroup search is used when the Collection Path doesn't begin with a /
.
It would be helpful to update the documentation for the collection path to indicate that it will use a collectionGroup query if the Collection Path does not start with a slash.
I have these collections: events users > events
Algolia is getting the users/events instead of getting events
Edit: This only occurs in existing records. New records do not experience this issue