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

Risk of race condition when deleting journal collection ? #204

Open
gbrd opened this issue Oct 9, 2018 · 3 comments
Open

Risk of race condition when deleting journal collection ? #204

gbrd opened this issue Oct 9, 2018 · 3 comments

Comments

@gbrd
Copy link
Contributor

gbrd commented Oct 9, 2018

When we do (in CasbahPersistenceJournaller.deleteFrom() for example) :

    if (driver.useSuffixedCollectionNames && driver.suffixDropEmpty && journal.count() == 0) {
      journal.dropCollection()
      ...

Is there a risk that documents are inserted in collection between test and drop ?

@scullxbones
Copy link
Owner

Fixed by #205 - released with v2.1.1. Thanks @gbrd!

@gbrd
Copy link
Contributor Author

gbrd commented Nov 5, 2018

This one is independent and may not be fixed bar #205 right ?

@scullxbones
Copy link
Owner

My mistake.

@scullxbones scullxbones reopened this Nov 5, 2018
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

No branches or pull requests

2 participants