[SERVER-47313] Allow clients to add context to oplog Created: 02/Apr/20 Updated: 07/Aug/23 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | Write Ops |
| Affects Version/s: | 4.2.5 |
| Fix Version/s: | None |
| Type: | New Feature | Priority: | Major - P3 |
| Reporter: | Dave Vasilevsky | Assignee: | Alan Zheng |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Sprint: | Repl 2020-04-20 |
| Participants: |
| Description |
|
When a document is mutated, it would be very handy to be able to audit what caused the mutation to happen. However, the oplog doesn't currently include much client context. Ideally, clients could add some context, eg:
And then this context could appear in the oplog:
|
| Comments |
| Comment by Dave Vasilevsky [ 28/Jan/21 ] |
|
Here's a patch we've been running for a bit against 3.6.9: https://github.com/vasi/mongo/commit/234089669bb3f779f926549850a8311939a70718 . We also have one against 4.0, it's similar. Is this something Mongo upstream is interested in? |
| Comment by Dave Vasilevsky [ 09/Apr/20 ] |
|
We're working on rolling out a patch against 3.6 locally, we'd be happy to share privately for now (and publicly once we do more testing and make sure it's safe). |
| Comment by Carl Champain (Inactive) [ 03/Apr/20 ] |
|
Hi vasi@stripe.com, Thank you for the report. Kind regards, |