Skip to content

Sre 2645 added more loging #5

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
Jan 14, 2019

Conversation

ikapriz-objectrocket
Copy link

@ikapriz-objectrocket ikapriz-objectrocket commented Jan 14, 2019

  1. https://github.com/objectrocket/mongodb_consistent_backup/pull/5/files#diff-65088d69efbeaed14dc17e0374cc6752R92 - changed oplog tailer connection to login to a single server in replica set instead of pool of servers in replica.
  2. https://github.com/objectrocket/mongodb_consistent_backup/pull/5/files#diff-f7f0fc30ff8a9b245c806958c07df179R106 in race condition on several occasions the tailer cursor gets stopped while we are checking in the loop for oplog to reach particular point in time. New check prevents infinite looping.

We ended up not using oplog trailer feature at all on our instances so that code is not working in production. All other changes are additional logging

Copy link

@chacon chacon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add the other changes about the Oplog Tailer as well to a description? The changes look fine, though.

# wait for replication to get in sync
while state.get('last_ts') and state.get('last_ts') < timestamp:
# wait for replication to get in sync making sure cursor has not been stopped in a race condition
while state.get('last_ts') and state.get('last_ts') < timestamp and not self.shards[shard]['thread'].stopped:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like the first condition is unnecessary if the second depends on it anyway.

@ikapriz-objectrocket ikapriz-objectrocket merged commit 1b51991 into master Jan 14, 2019
@ikapriz-objectrocket ikapriz-objectrocket deleted the SRE-2645-added-more-loging branch January 14, 2019 19:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants