[ 
https://issues.apache.org/jira/browse/GEODE-6404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16777181#comment-16777181
 ] 

ASF subversion and git services commented on GEODE-6404:
--------------------------------------------------------

Commit 2be6375a775b6b0d00d0c41a1e2a3bf4b8745a46 in geode's branch 
refs/heads/develop from Jason Huynh
[ https://gitbox.apache.org/repos/asf?p=geode.git;h=2be6375 ]

GEODE-6404: work around possible sync issue with computeIfAbsent (#3196)

* GEODE-6404: work around possible synchronization issue with computeIfAbsent

  *  Tries to do the get() outside of a lock before computing
  *  Added jmh test
  *  Local benchmarking showed that although jdk 11 fixes the contention issue 
that
       performing the get was faster than the retrieve mechanism of 
computeIfAbsent


> review use of computeIfAbsent across code base
> ----------------------------------------------
>
>                 Key: GEODE-6404
>                 URL: https://issues.apache.org/jira/browse/GEODE-6404
>             Project: Geode
>          Issue Type: Bug
>          Components: general
>            Reporter: Jason Huynh
>            Assignee: Jason Huynh
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 2h
>  Remaining Estimate: 0h
>
> It looks like computeIfAbsent on a ConcurrentHashMap is a blocking method.  
> This may run against what the developer was expecting when using the method.  
> This ticket to for someone to go through code base and modify (if necessary) 
> with a get/null check before computing or some other pattern.
> See [https://bugs.openjdk.java.net/browse/JDK-8161372]  
> Related to GEODE-6403 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to