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

Improve warning message in the logs around removal of legacy op codes

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.0.0-rc9, 6.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Fully Compatible
    • v6.0
    • QE 2022-05-30, QE 2022-06-13

      In 5.1, we removed support for OP_QUERY commands, as well as the legacy op codes in general (OP_QUERY find operations, OP_GET_MORE, OP_INSERT, OP_UPDATE, etc.). If a 5.1+ server receives a wire protocol message that is no longer supported, it will bump a counter in db.serverStatus().opcodes.deprecated, return an error to the client (or close the connection if the op code is "fire and forget"), and produce a warning in the logs like this:

      {"t":{"$date":"2022-05-25T16:38:22.917+00:00"},"s":"W",  "c":"COMMAND",  "id":5578800, "ctx":"conn242","msg":"Deprecated operation requested. For more details see https://dochub.mongodb.org/core/legacy-opcode-compatibility","attr":{"op":"query","clientInfo":{"address":"127.0.0.1:60450"}}}
      

      This log message is stale. It should be updated to say not just that the operation is deprecated but that it is no longer supported. We also should create a new dochub link which points not to the information about op code deprecation in 5.0, but rather to information pertaining to the removal of support for these op codes in 5.1. For example, we could point to the relevant compatibility changes docs associated with the 5.1 release notes: https://www.mongodb.com/docs/upcoming/release-notes/5.1-compatibility/#legacy-opcodes-removed.

            Assignee:
            david.storch@mongodb.com David Storch
            Reporter:
            david.storch@mongodb.com David Storch
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: