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

gFeatureFlagUpdateOneWithoutShardKey flag in CRI should use safer methods to check if feature flag is enabled.

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.0.0-rc0, 7.3.0-rc4
    • Affects Version/s: None
    • Component/s: None
    • None
    • Cluster Scalability
    • Fully Compatible
    • ALL
    • v7.3
    • Cluster Scalability 2024-3-4
    • 122

      The linked BF is failing in the sharded_collections_uninitialized_fcv_jscore_passthrough suite for a CSRS. node. This suite starts an initially syncing CSRS node with FCV set to uninitialized. It also hangs in this failpoint before an oplog collection is created on the node. The test that hits the feature flag check is jstests/core/administrative/list_all_sessions.js when it tries to refresh a session.

       

      Shard server catalog cache loader (which the CSRS was using until SERVER-84548) on the CSRS does a `performNoopMajorityWriteLocally` here which writes to the oplog which would have failed for this node with the error: 
      "error":"NotYetInitialized: The oplog does not exist." because the oplog doesn't exist yet (because of the reason described above). This suite will ignore this error (since it's concerned about uninitialized FCV checks rather than test correctness)
       
       
      With SERVER-84548, we started using the Config Server Catalog Cache Loader on the CSRS, which doesn't do a similar local no-op write, causing the refresh to proceed as usual and call cluster::write which will call the gFeatureFlagUpdateOneWithoutShardKey  check in src/mongo/s/collection_routing_info_targeter.cpp targetUpdate() with an uninitialized FCV causing this failure.
       
      We should either use isEnabledUseLastLTSFCVWhenUninitialized or isEnabledUseLatestFCVWhenUninitialized when checking this flag.

            Assignee:
            kshitij.gupta@mongodb.com Kshitij Gupta
            Reporter:
            kshitij.gupta@mongodb.com Kshitij Gupta
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: