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

Move the uuid and empty fields of create sharded collection logging to the end event

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Fully Compatible
    • Sharding EMEA 2021-05-17

      When creating a sharded collection there are two events being reported:

      • shardCollection.start with the shardKey, uuid, a flag to check if the collection is empty and the shardId
      • shardCollection.end with two parameters: number of chunks created and the collection version

      The uuid and the empty flag can only be determined after the _createCollectionAndIndexes step is executed, because we can check if the collection is empty after taking the critical section, and if there was no collection, that's the point where the uuid is created. If we move both parameters to the shardCollection.end event, then we can move the logging to the beginning kCommit phase (or maybe even to the kCheck phase). However, right now we don't know if this logging is being used, so, before doing the change we should do a quick check who's possibly using it.

            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: