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

Rename BatchBoundaries::start to be "begin"

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor - P4
    • Resolution: Gone away
    • Affects Version/s: 3.2.0
    • Fix Version/s: None
    • Component/s: Replication
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible

      Description

      The member inside BatchBoundaries is called "start", but the corresponding field inside the minvalid doc is called "begin". This mismatch hinders the readability of the code, especially for people who are unfamiliar with it.

      It also means that some error messages refer to the "start" timestamp, even though this timestamp is called "begin" in minvalid, eg. this one:

      if (!mv.start.isNull()) {
          // If we are in the middle of a batch, and recoveringm then we need to truncate the oplog.
          LOG(2) << "Recovering from a failed apply batch, start:" << mv.start.toBSON();
          truncateOplogTo(txn, mv.start.getTimestamp());
      }
      

      Since changing the minvalid field name would be needlessly difficult, it would be good to change the relevant occurrences of "start" in the code to "begin".

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                kevin.pulo Kevin Pulo
                Reporter:
                kevin.pulo Kevin Pulo
                Participants:
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: