I am trying to track down some concurrency issues related to collections in a large code base.
I would like to replace all collections / maps with an alternative implementation that throws an exception when a third thread accesses it (or similar, I see several possible strategies that might work). Does anyone know of any libraries / tools / strategies for this?
I was thinking about replacing the search in the entire codebase and just temporarily replacing any link to things like the “new HashMap” with a different version. But maybe there is a better way?
source
share