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

Find a better way of setting the shardId when throwing on getCollectionDescription

    • Fully Compatible
    • Sharding 2020-04-20

      SERVER-45781 introduced the assurance of getting the latest collection description metadata available on the shard. This implies that if the metadata is unknown, then a Stale Shard Version Exception will be thrown. As part of the Exception construction a shardId must be provided. Currently the ServiceContext is being captured at the constructor, which is being used to get the ShardingState, however, there is an invariant that can be hit if for example a server with

      --shardsvr

      does some operations before being added into a cluster.

            Assignee:
            marcos.grillo@mongodb.com Marcos José Grillo Ramirez
            Reporter:
            marcos.grillo@mongodb.com Marcos José Grillo Ramirez
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: