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

Track counters for each command

    XMLWordPrintable

    Details

    • Backwards Compatibility:
      Minor Change
    • Sprint:
      Server 2.7.4, Server 2.7.5, Server 2.7.6

      Description

      For each command we should track a counter, like opcounters in serverStatus and a gauge for the active/waiting operations by command type.

      This will provide a counter for each command showing the number of times it has been executed and the number of times that the execution has failed. It will also track the number of times any unknown/invalid command is executed.

      This will track writes that are issued via the write command syntax. Due to this the values between the already existing command counter and the new counters may be off.

      Example shell usage:

      > db.serverStatus().metrics.commands
      {
              "<UNKNOWN>" : NumberLong(0),
              "_getUserCacheGeneration" : {
                      "failed" : NumberLong(0),
                      "total" : NumberLong(0)
              },
              "_isSelf" : {
                      "failed" : NumberLong(0),
                      "total" : NumberLong(0)
              },
              "_mergeAuthzCollections" : {
                      "failed" : NumberLong(0),
                      "total" : NumberLong(0)
              },
              "_migrateClone" : {
                      "failed" : NumberLong(0),
                      "total" : NumberLong(0)
              },
              "_recvChunkAbort" : {
                      "failed" : NumberLong(0),
                      "total" : NumberLong(0)
              },
      ...
      }
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              david.hows David Hows
              Reporter:
              scotthernandez Scott Hernandez
              Participants:
              Votes:
              2 Vote for this issue
              Watchers:
              8 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: