jbertram commented on pull request #3952: URL: https://github.com/apache/activemq-artemis/pull/3952#issuecomment-1037388502
Using `CopyOnWriteArrayList` is better than using `synchronized` relatively speaking, but I'm still not in favor of a change that is going to have such a widespread impact for an issue that seems confined to the STOMP implementation. As noted previously, I recommend you track down the root cause of the concurrent access and add protection there. As far as testing goes. I will typically write a system/integration test that brute forces the issue to occur. For example, if there's a race condition in connection handling then I'll spin up a few hundred threads and create as many connections as possible as quickly as possible. Once I can brute force the issue semi-reliably then I'll gather logging to narrow down the issue until the root cause is clear at which point a proper fix can be applied. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
