Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-10061

Docs for SERVER-15359: Provide "id" of collection

    • Type: Icon: Task Task
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 3.5.5
    • Affects Version/s: None
    • Component/s: Server
    • Labels:
      None

      Documentation Request Summary:

      listCollections output now includes a UUID to uniquely identify a collection.

      Engineering Ticket Description:

      It would be very helpful for clients, like replication or sharding, to track collection via a unique id which doesn't change during a rename or restarts. The "id" should be the same across replicas in a set or shards in a sharded cluster. Note: There is already an _id in sharding metadata for a collection but that is not exposed.

      Here is an example of output from listCollections with an "id":

      > db.runCommand("listCollections")
      {
      	"collections" : [
      		{
      			"id" : NumberLong("70368744177664"),
      			"name" : "system.indexes",
      			"options" : {}
      		}
      	],
      	"ok" : 1
      }
      

            Assignee:
            jeffrey.allen@mongodb.com Jeffrey Allen
            Reporter:
            emily.hall Emily Hall
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:
              6 years, 30 weeks ago