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

remove CommandInvocation::secondaryAllowed

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor - P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.7.6
    • Component/s: Internal Code
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Sprint:
      Platforms 2018-04-23

      Description

      The slaveOk,slaveOverrideOk properties of each command are informed by the "secondaryAllowed" result enum. For some commands the correct answer would depend on what the request payload is. So when "listCommands" prints out an array of all the commands and their "slaveOk", "slaveOverrideOK" bool properties, it has no way of telling the truth right now.

      This is user-facing.

      So now we have a secondaryAllowed virtual function on Command and another on CommandInvocation. The one on Command gives a Request-insensitive answer, and the one on CommandInvocation gives a Request-sensitive answer. For the majority of commands these will give the same answer and CommandInvocation's default implementation will be to call its Command's secondaryAllowed member.

      This ticket only covers removing secondaryAllowed from CommandInvocation, with the understanding that listCommands may have to be addressed at some point.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: