Use AutoCollection instead of AutoCollectionForRead

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Won't Fix
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • ALL
    • 63
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      Free Monitoring uses AutoCollectionForRead, unfortunately using this class can cause a deadlock with replication during startup. The deadlock can occurs because two the collection MODE_IS lock and _mutex in ReplicationCoordinatorImpl are taken in different orders The ReplicationCoordinatorImpl::_finishLoadLocalConfig method takes the {{_mutex first and then MODE_IS lock while AutoCollectionForRead takes it in the opposite order.

      A simple fix is to switch to AutoCollection since free monitoring does not need to wait for changes to replicate when it polls the local admin database on the primary or secondary.

            Assignee:
            Mark Benvenuto
            Reporter:
            Mark Benvenuto
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: