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

Add info-level logging for DDL oplog entries on primary and secondaries

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Replication
    • Fully Compatible
    • Repl 2023-03-06
    • 168

      Recently we tried to diagnose a case in which a createCollection oplog entry was missing on the primary / secondaries. From the logs we could see that the createCollection event had occurred on the primary, but we weren't able to determine what the opTime of the event was from the logs. This made it harder to diagnose the problem.

      If we want to just log this for createCollection, we can add the opTime information to this log line: https://github.com/10gen/mongo/blob/f9310b523138aa8a79b61797a42748df006cf1b8/src/mongo/db/catalog/database_impl.cpp#L828.

      However, it would be nice to log the optimes of all DDL events and possibly CRUD events as well, if the customer has the correct logging level on. This may require logging at the point we actually apply an event to the oplog.

            Assignee:
            kaitlin.mahar@mongodb.com Kaitlin Mahar
            Reporter:
            vishnu.kaushik@mongodb.com Vishnu Kaushik
            Votes:
            0 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated:
              Resolved: