Merged
Conversation
Test Results 32 files ±0 32 suites ±0 9m 55s ⏱️ + 1m 50s Results for commit d5c8c26. ± Comparison against base commit 4567b99. This pull request removes 4 and adds 5 tests. Note that renamed tests count towards both.♻️ This comment has been updated with latest results. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The PR adds a test from #165 repro into SQL Server test suite. It, indeed, crashed when checkpointing from time to time as the observable produced an error. A different question would be if something should happen with the subscription if the observable crashes for any reason, but it's out of scope.
So, what I found out is that pushing checkpoint batches through the observable caused the sequence to be updated in parallel with adding new stuff to it, as well as collection manipulation wasn't exactly sequential.
To fix the issue, I added a semaphore to control access to the sequence. It solved the issue, and it doesn't have much performance hit as the operation is done per checkpoint batch. One thing that helps in such a scenario is to increase the commit batch size so it doesn't try to checkpoint very often. The test has 1000 as the batch size.
So, basically, it works now :)