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

shard-local db and collection caches may not contain timestamps after upgrade in the presence of configsvr stepdowns

    XMLWordPrintable

    Details

    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL

      Description

      In SERVER-53104 we make the configsvr tell the shards to refresh their db/collection caches after patching up the configsvr metadata as part of FCV upgrade.

      In the presence of configsvr stepdowns, it cannot be ensured that the shard-local caches will be refreshed. Consider the following situation:

      1. Configsvr patches up config.databases to $set the 'timestamp' field. Then configsvr crashes here.
      2.  On the next setFCV invocation, ShardingCatalogManager::_createDBTimestampsFor49 will be ran again, but it won't find any document in config.databases that matches the query '{timestamp: {$exists: false}}', so this tellShardsToRefreshDatabase won't execute because 'dbDocs' will be empty.

      This same situation can happen for config.collections refresh here and here.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jordi.serra-torrens Jordi Serra Torrens
              Reporter:
              jordi.serra-torrens Jordi Serra Torrens
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: