summaryrefslogtreecommitdiff
path: root/src/mongo/db/update/update_oplog_entry_serialization.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/update/update_oplog_entry_serialization.h')
-rw-r--r--src/mongo/db/update/update_oplog_entry_serialization.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mongo/db/update/update_oplog_entry_serialization.h b/src/mongo/db/update/update_oplog_entry_serialization.h
index 24ace4c3315..a438c9ee5e2 100644
--- a/src/mongo/db/update/update_oplog_entry_serialization.h
+++ b/src/mongo/db/update/update_oplog_entry_serialization.h
@@ -67,6 +67,11 @@ enum class FieldRemovedStatus { kFieldRemoved, kFieldNotRemoved, kUnknown };
BSONObj makeDeltaOplogEntry(const doc_diff::Diff& diff);
/**
+ * Given a $v: 2 delta-style oplog entry, return the embedded diff object.
+ */
+boost::optional<BSONObj> extractDiffFromOplogEntry(const BSONObj& opLog);
+
+/**
* Produce the contents of the 'o' field of a replacement style oplog entry.
*/
inline BSONObj makeReplacementOplogEntry(const BSONObj& replacement) {