Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-62780

Create tenantId decoration on opCtx for use by background threads

    • Type: Icon: Task Task
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None

      Background threads that create operation contexts and do work on behalf of tenants will need to set the tenantId on the opCtx they create. Create a new tenantId decoration on the opCtx, similar to dollarTenantDecoration, for use by by such threads. This decoration should only be able to be set when multitenancySupport is enabled, and neither dollarTenantDecoration nor securityTokenDecoration are set (see parseDollarTenantFromRequest for how we can check for multitenancySupport and the securityTokenDecoration) .

      getActiveTenant should return the tenantId on this object if it exists.

            Assignee:
            hugh.tong@mongodb.com Hugh Tong (Inactive)
            Reporter:
            janna.golden@mongodb.com Janna Golden
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: