Topology manager import optimisation#59
Conversation
|
Thanks for the PR! Optimizations and cleanup are always welcome, however after reviewing it there are still a few concerns/thoughts that come to mind. I'm mostly concerned since we've had quite a few concurrency issues in the past (ConcurrentModificationExceptions, deadlocks, race conditions etc) so making big changes relating to concurrency should probably be reviewed in great detail and load tested somehow.
Sorry for the long list, but as I said I'm wary of making big changes to multiple concurrency mechanisms in code that proved trickier than it seems in the past, without clear advantages - "if it ain't broke..." :-) That being said, if everyone's convinced it's all good and a real improvement then I'm all for it! |
388695f to
4d802ff
Compare
4d802ff to
4d31e21
Compare
|
Thanks for having a look. That's a big list. I hope most of the points are covered now |
|
Could you please clarify what is the bug being solved here? Are you experiencing a performance bottleneck that needs to be optimized, or are there concurrency issues? Could you elaborate on the use case where this change is needed and the current implementation is insufficient, maybe with a more concrete example? |
This update addresses the issue where multiple events related to the same filter could cause the same number of threads from the executor in the
TopologyManagerImportclass to operate on the sameImportRegistrationobjects, resulting in diminished throughput.To resolve this, the proposed change ensures that each import registration or closing of an import registration is managed by a single thread within the executor of the topology manager. As a result, when multiple events occur for the same filter, only one thread will be responsible for the import or closing of each
ImportRegistration.