Provide an easy way to check if moveCollection was successful

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Duplicate
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Cluster Scalability
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      Today, when a user runs moveCollection, they have to understand that collections that are moved are tracked in the config db. They have to find the UUID of a collection using

      db.getCollectionInfos() and then query config.chunks with the UUID of the collection to check if moveCollection was successful. Also, config.chunks stores tracked collections with metadata similar to sharded collections which can be confusing for the customer.
      Output of config.chunks for a tracked collection:

      use config 
      db.chunks.find({ uuid: UUID('128b952c-cbfb-43e5-b06d-20fd812185ac')})
      [
        {
          _id: ObjectId('6791a28cded50da65eaf79d4'),
          uuid: UUID('128b952c-cbfb-43e5-b06d-20fd812185ac'),
          min: { _id: MinKey() },
          max: { _id: MaxKey() },
          shard: 'atlas-kyaq94-shard-3',
          lastmod: Timestamp({ t: 1, i: 4 }),
          onCurrentShardSince: Timestamp({ t: 1737597580, i: 53 }),
          history: [
            {
              validAfter: Timestamp({ t: 1737597580, i: 53 }),
              shard: 'atlas-kyaq94-shard-3'
            }
          ]
        }
      ]
      

      Provide an easy interface to check if moveCollection was successful without using the UUID as an input.

            Assignee:
            Unassigned
            Reporter:
            Ratika Gandhi
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: