Q: about the API keys feature and using it for multi-tenancy … I take it each tenant still needs to have their own separate collection, otherwise document IDs could conflict?
j
Jason Bosco
08/30/2021, 12:35 AM
@CaptainCodeman Not necessarily, you can put all tenants documents in a single collection... Unless document IDs between tenants collide on your end?
c
CaptainCodeman
08/30/2021, 1:14 AM
there's no guarantee they won't, so I'll create separate collections. I wondered if it worked like AppEngine Datastore where each namespace could have their own unique data, even for the same IDs
j
Jason Bosco
08/30/2021, 1:15 AM
You could generate document IDs using a prefix on your side. So something like
tenantId-documentId
c
CaptainCodeman
08/30/2021, 2:41 AM
that would work too, and I guess give the option of querying one or all