You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Concurrent and Synchronized are two different things: This is synchronized, not concurrent #112
Currently, these classes are not concurrent, they are synchronized.
Concurrent classes allows scaling and would actually allow multiple threads to make changes to the same collection. This is made possible by not synchronizing on the whole collection, but on individual "buckets" inside the collection.
Synchronized classes does not scale and only allows one thread to make changes.
I would recommend to clarify this by changing the names (although that would be a breaking change, so maybe use a deprecated typealias to support backwards compatibility) and adding to the readme that the collections use synchronization on a single object to make them thread-safe, and that they are not concurrent.
An even better solution would however of course be to make the collections properly concurrent.
Activity
lukellmann commentedon Jun 30, 2024
this fact brings issues like #105