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

Insert no-op entries into oplog buffer collections for resharding so resuming is less wasteful

    • Fully Compatible
    • v5.0
    • Sharding 2021-07-12, Sharding 2021-07-26, Sharding 2021-08-09
    • 2

      Insert a no-op entry with

      Unable to find source-code formatter for language: javascritp. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
      {_id: {
          clusterTime: <latest oplog timestamp from donor's cursor response>,
          ts: <latest oplog timestamp from donor's cursor response>,
      }}
      

      into the oplog buffer collection on the recipient shard. The <latest oplog timestamp from donor's cursor response> refers to the getLatestOplogTimestamp() value exposed in aggregation cursor command responses on oplog from SERVER-49895.

      The no-op entry should be inserted using its own storage transactions and its Collection::insertDocument() call must be allowed to fail with a duplicate key error. This is because it is possible for the donor shard to not have generated any more oplog entries since the last getMore the recipient shard sent and therefore for the same getLatestOplogTimestamp() to be returned.

            Assignee:
            janna.golden@mongodb.com Janna Golden
            Reporter:
            max.hirschhorn@mongodb.com Max Hirschhorn
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: