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

Consider that removeShardStatus response may reach the max BSON size

    • Type: Icon: Task Task
    • Resolution: Gone away
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing

      The output of reamoveShardStatus may reach the maximum BSON size (BSONObjMaxUserSize) if a draining shard has lots of collections.

      In case of reaching this limit, the affected document will be truncated and we'll add extra info to that document to notify that it has been truncated.

      These will be the fields attached to a truncated document for a draining shard:

      • "totalNumOfDatabases"
      • "totalNumOfShardedCollections"
      • "totalNumOfUnshardedCollections"
      • "truncated": boolean field set to true
      • "note": a human-readable explanation about why the current document has been truncated.

      This is how a truncated document would look like:

      {
         "shard": "shard5",
      
         "databasesWithShardAsPrimary": [ ... ],
         "unshardedCollections": [ ... ],
         "shardedCollections": [ ... ],
      
         "totalNumOfDatabasesWithShardAsPrimary": 2,
         "totalNumOfShardedCollections": 4000,
         "totalNumOfUnshardedCollections: 5000,
         "truncated": true, 
         "note": "The output has been truncated due to too many databases/collections"
      }

            Assignee:
            Unassigned Unassigned
            Reporter:
            silvia.surroca@mongodb.com Silvia Surroca
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: