You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ofbiz.apache.org by GitBox <gi...@apache.org> on 2026/09/02 05:41:31 UTC

[GH] (ofbiz-framework/backport-1835-tenant-resolution): Workflow run "Java CI with Gradle" failed!

The GitHub Actions job "Java CI with Gradle" on ofbiz-framework.git/backport-1835-tenant-resolution has failed.
Run started by GitHub user ashishvijaywargiya (triggered by ashishvijaywargiya).

Head commit for run:
81c01b3692eaeb795e90512af5ceb75b6b30b74f / Krishna Uprit <kr...@gmail.com>
Improved: Align tenant resolution between LoginWorker and ContextFilter (#1835)

`ContextFilter` and `LoginWorker` each resolve `userTenantId` for a request but use opposite precedence, and `ContextFilter` updates the session `delegatorName` in place when the resolved tenant changes. This makes the two consistent.

- `LoginWorker.login(...)` now resolves `userTenantId` the same way
  `ContextFilter` already does: request attribute first, request parameter as
  fallback. Previously it read the parameter first, so the two could resolve
  different tenants for the same request.

- `ContextFilter` now compares the tenant encoded in the session's existing
  `delegatorName` (`name#tenantId`) against the tenant resolved for the current
  request. When they differ it invalidates the session, so `dispatcher`,
  `security` and `userLogin` are rebuilt for the current tenant on the next
  request instead of `delegatorName` alone being overwritten. A warning is
  logged when this happens.

No change for single-tenant deployments or when the session tenant and the request tenant already match.

Thank you Krishna Uprit for the contribution.

Co-authored-by: Krishnauprit18 <kr...@users.noreply.github.com>

(cherry picked from trunk's commit 39ec4fda5c36094ea902b138a7eb2645f6d5dee4)

Report URL: https://github.com/apache/ofbiz-framework/actions/runs/33595643215

With regards,
GitHub Actions via GitBox