Skip to content

Conversation

mrjoe7
Copy link

@mrjoe7 mrjoe7 commented Jul 15, 2025

Motivation

We’re adding change.stream.lookup.full.document.before.change to ensure that we can access the full document prior to a delete operation in MongoDB change streams.

This is particularly important for our use case where:

  • Deleted documents must be preserved for downstream consumers.
  • The delete change event by default does not include the document body — without enabling pre-images, we would lose all context about what was removed.
  • Having the pre-image ensures that we can reconstruct the full lifecycle of a document (create → update → delete) from the change stream alone.

We’re setting this as a configurable option to remain compatible with MongoDB deployments.

@mrjoe7 mrjoe7 requested a review from a team as a code owner July 15, 2025 16:00
@mrjoe7 mrjoe7 requested review from stIncMale and removed request for a team July 15, 2025 16:00
@stIncMale stIncMale requested review from rozza and removed request for stIncMale August 27, 2025 20:36
@rozza
Copy link
Member

rozza commented Sep 1, 2025

Hi @mrjoe7,

Thanks for the PR - this looks like a great addition to the connector. I've added SPARK-449 to Jira to get this triaged and plan work.

I'm not sure we have any time planned this quarter for a release but will try to get this added asap.

Ross

@rozza rozza removed their request for review September 4, 2025 09:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants