xtern commented on code in PR #4762: URL: https://github.com/apache/ignite-3/pull/4762#discussion_r1855985640
########## modules/transactions/src/main/java/org/apache/ignite/internal/tx/impl/HeapLockManager.java: ########## @@ -251,22 +251,18 @@ public void releaseAll(UUID txId) { } } + @Override + public Iterator<Lock> locks() { Review Comment: To get active tx list we need to filter values from VolatileTxStateMetaStorage#txStateMap. This map contains not only active txs, but finished txs also (for some time). In addition, calculating the hash code for each element and randomly reading elements from the map also looks less efficient than simple sequential iteration. ########## modules/transactions/src/main/java/org/apache/ignite/internal/tx/impl/HeapLockManager.java: ########## @@ -251,22 +251,18 @@ public void releaseAll(UUID txId) { } } + @Override + public Iterator<Lock> locks() { Review Comment: To get active tx list we need to filter values from VolatileTxStateMetaStorage#txStateMap. This map contains not only active txs, but finished txs also (for some time). In addition, calculating the hash for each element and randomly reading elements from the map also looks less efficient than simple sequential iteration. -- 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: notifications-unsubscr...@ignite.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org