Skip to content
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

feat(db,sync): atomic sync transactions #19

Merged
merged 4 commits into from
Jan 13, 2025
Merged

Conversation

mempirate
Copy link
Contributor

No description provided.

@mempirate mempirate requested a review from merklefruit January 10, 2025 14:20
Copy link
Contributor

@merklefruit merklefruit left a comment

Choose a reason for hiding this comment

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

Great!

Comment on lines +153 to +162
// Start a new sync transaction. This transaction atomically executes the following
// operations:
// - Register new validators from external sources
// - Register their associated operators from external sources
// - Register new operators from contract events
// - Update the state table
let Ok(mut sync_transaction) = self.db.begin_sync().await else {
error!("Failed to begin sync transaction");
return;
};
Copy link
Contributor

Choose a reason for hiding this comment

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

lovely

@mempirate mempirate merged commit fea6e3d into main Jan 13, 2025
1 of 3 checks passed
@mempirate mempirate deleted the jonas/feat/db-transactions branch January 13, 2025 09:50
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