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

Fixing concurrency issue in Memory Cache #266

Merged
merged 1 commit into from
Sep 25, 2019

Conversation

jkernsva
Copy link
Contributor

I'm seeing some System.IndexOutOfRangeException exceptions in our
application caused by corruption of the child regions HashSet. This
appears to be caused by concurrent writes to the data structure. I'm
replacing the HashSet with a ConcurrentDictionary. This isn't ideal as
each key also has to store a bogus value, but there is no builtin
concurrent HashSet and this seemed to be a better solution than explicit
locking.

I'm seeing some System.IndexOutOfRangeException exceptions in our
application caused by corruption of the child regions HashSet. This
appears to be caused by concurrent writes to the data structure. I'm
replacing the HashSet with a ConcurrentDictionary. This isn't ideal as
each key also has to store a bogus value, but there is no builtin
concurrent HashSet and this seemed to be a better solution than explicit
locking.
@DamianKedzior
Copy link

Hi @MichaCo,
do you have plan to merge this PR and release it? Does it requires some additional testing? Could community help somehow with this?

@MichaCo
Copy link
Owner

MichaCo commented Sep 10, 2019

Hey,
I'm sorry that this is still not merged. A lot of stuff going on right now...

But, I'll try to find some time and get a new release out with this and some other minor things as soon™ as I can

@MichaCo MichaCo merged commit f2d6e11 into MichaCo:dev Sep 25, 2019
@tynorton
Copy link

tynorton commented Dec 5, 2019

When can we get an updated NuGet with this fix? Problem is affecting us.

@pergardebrink
Copy link

We hit the problem as well with the same exception (tried to move to this because of #313).

Is it possible to get a new release of 1.x? Or the 2.0 with netstandard2.0 support for System.RuntimeCaching? Can I/we help out in any way?

@pergardebrink
Copy link

Just wondering if there's anything I can do to help with getting this out into 1.2 or 2.0 in some way?

I'm trying to move some stuff from .NET Framework to .NET Core/.NET 5 and got stuck in between this issue here and #313 .. Or is there any other way of getting a memory cache in CacheManager when targeting .NET Core/._NET 5?

@NinjaCross
Copy link

Are there news about this ?
This is impacting heavily multiple applications of my customers.

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.

6 participants