agura commented on a change in pull request #6976: IGNITE-6804 Warning if
unordered map used in locking cache operation.
URL: https://github.com/apache/ignite/pull/6976#discussion_r372385433
##########
File path: modules/core/src/main/java/org/apache/ignite/IgniteCache.java
##########
@@ -919,6 +928,10 @@
* <p>
* In Default Consistency mode, individual puts occur atomically but not
* the entire putAll. Listeners may observe individual updates.
+ * <p>
+ * Keys are locked in the order in which they appear in map. It is
caller's responsibility to
+ * make sure keys always follow same order, such as by using {@link
TreeMap}. Using unordered map,
+ * such as {@link HashMap}, while calling this method in parallel <b>will
lead to deadlock</b>.
Review comment:
Please add imports for `HashMap` and `TreeMap` or use fully qualified name.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services