[DOCS-12074] [Server] Update Oplog page to specify that it only adds an entry on success; link command pages as required Created: 25/Sep/18  Updated: 22/Jan/24

Status: Backlog
Project: Documentation
Component/s: Server
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Daniel Coupal Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: backlog, query, quick-win, replication, request, server-docs-bug-bash
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:
Days since reply: 5 years, 19 weeks, 6 days ago

 Description   

Description

Let's add a mention in the documentation where we precise what happen to replication for the different "delete" methods.
For example:

  • deleteMany resulting in many entries put on the Oplog
  • deleteXXX not finding any documents, not adding anything on the Oplog

Scope of changes

Add section on behavior of write commands that can fail (e.g. delete/update where query predicate finds no matching documents to modify) not adding oplog entries.

Add a section in the oplog docs to note that only write operations that succeed create an oplog entry.

Not in scope - wider audit of commands that generate oplog entries on success but not on failure.

Impact to Other Docs

MVP (Work and Date)

Resources (Scope or Design Docs, Invision, etc.)



 Comments   
Comment by Ravind Kumar (Inactive) [ 27/Sep/18 ]

We could potentially add a section to the Oplog page to state that for any given attempted write operation, the oplog only updates if the write succeeds. Might need some framing e.g. with majority committed writes, a write that fails the majority acknowledgement can succeed and result in an oplog event, despite the write concern failure. Would need to confirm with replication team as to whether this is generally applicable behavior, or whether some commands always generate an oplog event even on failure.

Otherwise, we can update the behavior section of the delete command and its related shell helpers to include a little blurb on the topic.

We might as well do the same for the update commands, as I assume they have the same affect (an update command that finds no documents to modify results in no oplog entries). Will also touch base with query w.r.t. what other commands result in oplog entries.

Generated at Thu Feb 08 08:04:20 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.