Skip to content

hotfix: Full Load while Log Based Sync #34

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Sep 25, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
improvement
hash-data committed Sep 25, 2024
commit 57ce7398c317de88d9b78dfe85b1f091f4f6ee11
4 changes: 3 additions & 1 deletion dz_mongodb/sync_strategies/change_streams.py
Original file line number Diff line number Diff line change
@@ -160,7 +160,9 @@ def sync_database(client: MongoClient,
# perform full load if no previous token exists
if full_load_on_empty_state:
# preserve resume token from oplog
first_resume_token = get_current_resume_token(client, database)
first_resume_token = None
if not start_after:
first_resume_token = get_current_resume_token(client, database)
for tap_stream_id in full_load:
table_name = streams_to_sync[tap_stream_id].get('table_name')
collection = database[table_name]