2 ms·
This reminds me of the whitepaper Scalability! But at what cost? http://www.frankmcsherry.org/assets/COST.pdf http://www.frankmcsherry.org/assets/COST.pdf Whi
by samsquire 3y ago
This reminds me of the whitepaper Scalability! But at what cost?
http://www.frankmcsherry.org/assets/COST.pdf http://www.frankmcsherry.org/assets/COST.pdf
Which I think is about how single threaded programs are faster than scalable but slow multithreaded systems.
I think you might be right and that's why there is ReadWriteLock or RwLock for single writer taking turns.
If you have a counter or a data structure you're mutating in every request then you'll hit lock contention.