[v6.0] Avoid resetting AuthorizationManager in AuthorizationSessionTestFixture

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Won't Do
    • Priority: Major - P3
    • None
    • Affects Version/s: 6.0.0
    • Component/s: None
    • None
    • Server Security
    • Server Security 2025-04-14, Server Security 2025-04-28, Server Security 2025-05-09
    • 200
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      AuthorizationSessionTestFixture inherits from ServiceContextMongodTest. The ServiceContextMongodTest constructor runs first and launches a separate thread for the JournalFlusher. The AuthorizationSessionTestFixture::setup() implementation runs after that and resets the AuthorizationManager to a separate instance. This can cause race conditions which result in transient failures.

      We should avoid resetting AuthorizationManager altogether in AuthorizationSessionTestFixture. If we have to, then we should ensure that the JournalFlusher is not started until the authorization manager has been fully reset.

              Assignee:
              Erwin Pe
              Reporter:
              Varun Ravichandran
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: