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

Get fullDocument and before/after within Change Stream Events

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      I am using Change Stream Events to get notified whenever a document is updated/deleted/inserted in a database collection.

      But they would be a lot more useful if I they would include the "previous" state of a document. Meaning that within a "deleted" event I could still access the contents of the deleted document and in an "updated" event I could get both versions (before and after) of an updated document.

      I am aware that the "updateDescription" describes the keys which have been changed and the latest value, but they don't include what the value was previously.

      I got the idea by working with the Document Database Firebase Firestore before. Within their updated/deleted/inserted events they do include both the "before" and "after" state for deleted/updated/created events. (Of course, in the case of deleted and in the case of created the after/before is empty respectively)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              backlog-server-triage Backlog - Triage Team
              Reporter:
              hello@growtheme.com Jascha Brinkmann
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: