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

moveChunk and shardCollection commands are not properly synchronized

    • Type: Icon: Bug Bug
    • Resolution: Won't Do
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Sharding EMEA
    • ALL
    • 127

      The current implementation of the shardCollection command enters the critical section, creates the configuration entry to the config server, then leaves the critical section.

      Between the collections creation and release of the critical section events, the newly created collection could be taken into account by the balancer (moveChunk command) which would not be able to enter the critical section.

      A possible solution consists in creating the collection entry with the allowMigrations flag set, then unset it with the _configsvrSetAllowMigrations once the critical section is left. Note this flag must be unset in a phase of the shardCollection that is resilient to stepdown/shutdown.

            Assignee:
            backlog-server-sharding-emea [DO NOT USE] Backlog - Sharding EMEA
            Reporter:
            antonio.fuschetto@mongodb.com Antonio Fuschetto
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: