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

fix: Use skip if not empty param #326

Conversation

gonzalezzfelipe
Copy link
Contributor

No description provided.

Comment on lines 209 to 213
if args.skip_if_not_empty & crate::common::open_wal(config).is_ok() {
info!("Skipping bootstrap, data already present.");
return Ok(());
}

Copy link
Member

Choose a reason for hiding this comment

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

I think this premature open_wal could lock the second one that does the actual import if the struct is not dropped.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh, didn't know that. I'll check, and maybe put this in a closure to make sure it is dropped

@gonzalezzfelipe
Copy link
Contributor Author

This is already the behaviour now, so closing the PR

@gonzalezzfelipe gonzalezzfelipe deleted the fix/use-skip-if-not-empty-param branch November 11, 2024 14:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

2 participants