In ash oban infer/bypass tenancy for action
Hello,
I have a AshOban trigger that runs an update action. In the update action you cannot specify
multitenancy :bypass
so it errors out with changesets require a tenant to be specified
this also if I'm specifying a read action that bypasses the tenancy. What is the best practice here allow global true in the multitenancy block?3 Replies
You could use
global? true
but there is also a list_tenants option for ash oban, that way it would run the scheduler for every tenant in the returned listok, thanks. list_tenants is not a great option because it runs the same query x times
with attribute based global is faster, with context you need list_tenants