I have many threads that can add items to collection and remove specific items from that collection on some condition. In first project, readers more than writers. In second project, readers may be more than writers or equal or less.
- How I should manage add/remove to that collection?
- What collection to use? Simple
List
with blocking on add/remove? - Which blocking mechanism to use(
lock
,ReaderWriterLockSlim
,...)?