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

Reset SynchronizedBlock cache after each iteration #510

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kzdev-net
Copy link

When an iteration is stopped due to the maximum step bound being hit, all the controlled threads/operations are abruptly interrupted which can leave orphaned entries in the Monitor.SynchronizedBlock.Cache. When subsequent iterations try to run, they are all guaranteed to fail quickly because they will find instances of SynchronizedBlock in the cache from the previous runtime.

This fix is to make sure the cache is cleared after each iteration run.

…ar out the object/Synchronized block cache.

Added an end iteration callback registration to the TestingEngine constructor that will clear out the Monitor.SynchronizedBlock cache after each iteration to be sure no entries carry over across iterations for cases such as the max step bound being hit and all controlled operations being abruptly stopped.
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.

1 participant