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

Fix undefined 'ns' variable bug in sharding_continuous_config_stepdown.js

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.5.10
    • Affects Version/s: None
    • Component/s: Sharding
    • Labels:
      None
    • Fully Compatible
    • ALL
    • TIG 2017-07-31
    • 0

      The ns variable is initialized here and can be undefined depending on whether the command is made using 'shardCollection' or 'shardcollection' – uppercase versus lowercase for the c --, both of which are legal calls.

      If the cmdObj is

      {shardCollection: 'foo.bar'.....}

      , then ns = cmdObj.shardCollection is defined, and the code works.

      However, if cmdObj is

      {shardcollection: 'foo.bar'....}

      , with a lowercase c, then ns = cmdObj.shardCollection is undefined, because javascripts discriminates upper and lower case.

            Assignee:
            max.hirschhorn@mongodb.com Max Hirschhorn
            Reporter:
            dianna.hohensee@mongodb.com Dianna Hohensee (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: