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

Determine correct ranges for priority in replicaSet configuration

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.2.0-rc0
    • Component/s: Replication
    • ALL

      In ReplSetConfig::MemberCfg::check:

      mchk(priority >= 0 && priority <= 1000); // <-- there is also a uassert below which makes this redundant?
      mchk(votes <= 100); // votes >= 0 because it is unsigned
      uassert(13419, "priorities must be between 0.0 and 100.0", priority >= 0.0 && priority <= 100.0);
      

      Note that the docs says priority is 0 <= x <= 1000, which contradicts the uassert above.

      http://docs.mongodb.org/manual/reference/replica-configuration/?highlight=priority#members[n].priority

            Assignee:
            matt.dannenberg Matt Dannenberg
            Reporter:
            randolph@mongodb.com Randolph Tan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: