The transition from nss-based names to uuid-based names of config.cache.chunk.* collections should be majority committed

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 5.1.0-rc0
    • Affects Version/s: None
    • Component/s: Sharding
    • None
    • Fully Compatible
    • ALL
    • Sharding EMEA 2021-07-26
    • 143
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The current implementation of ShardServerCatalogCacheLoader::_waitForTasksToCompleteAndRenameChunks doesn't wait for the rename operation to be majority committed. This is a problem because the shard might locally think that the operation was completed: it could happen that the timestamp was majority committed on config.cache.collections but not the renameCollection, so the next time that shard does a refresh it will think that the rename was completed.

      After discussing it with pierlauro.sciarelli, we agreed that this method should guarantee the following:

      • If a call to ShardServerCatalogCacheLoader::_waitForTasksToCompleteAndRenameChunks successfully completes, both renameOperation and updateTimestampOnShardCollections should be majority committed.
      • It should support to be called in a scenario in which the target collection already exists but the timestamp is not present on config.cache.collections.*.

            Assignee:
            Antonio Fuschetto
            Reporter:
            Sergi Mateo Bellido
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: