Queues, memory management and the ABA problem
Pools
- A pool is similar to a
Set with the following two distinctions:
- might not have a
contains() method for testing membership
- allows duplicate elements
- Pools usually act as buffers in producer<>consumer systems.
- Types of
Pool:
- Bounded:
- Number of items ==
capacity
- Useful when we want to limit the consumer lag.
- Unbounded
- Unlimited number of items
- Useful when we can’t fix a upper cap on the consumer lag.
Queues
Keywords
Linearizability
Sentinel Node
AtomicInteger
References