Replies: 2 comments 2 replies
We pretty much have to limit this discussion to For (B) just objects that are not tenanted. ... with TenantMode.PARTITION these are already cross tenant (there is no tenant column on those entities etc) - so perhaps I misunderstand what you mean here but (B) is a non-issue. That should leave us with (A) a query that would normally execute with TenantMode.PARTITION and add a predicate to the query limiting the result to the current tenant. So here a
That is what we mean here or did I misunderstand something? |
Yes I am using partition.
What I saw was that my current tenant provider was still being called even though the object didn't have a
Yes. This would be helpful for things like background tasks or cross tenant queries without having to do a bunch of threadlocal swaps for the current tenant (and therefore having to do multiple queries). Like I said I've worked around this by just using a second |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi Rob, I was wondering if you had any advice on opting out of multitenancy for specific queries. I have a decent amount of use cases for cross tenant queries or just objects that are not tenanted. It seems like it would be beneficial to be able to have something like:
.usingTenancy(false)on a query to opt out of automatically applying tenancy where clauses.I've gotten around this currently by using 2
Databaseobjects, one with tenancy enabled and one with it off, both using the same data source, but its much more complex than just being able to opt out for a query.Additionally, it might be a bug, but even for objects without
@TenantIdon them my current tenant provider is still being called.All reactions