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

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

Commit 59be42374785b7b02cb3e9050f797f41a7f6e014 in geode's branch 
refs/heads/develop from Barry Oglesby
[ https://gitbox.apache.org/repos/asf?p=geode.git;h=59be423 ]

GEODE-7466: Closed the existing CacheClientNotifier instance (#4338)



> HARegionQueueTest 
> queuePutElidesSequenceIdLowerThanOrEqualToLastSeenSequenceId can throw a 
> NullPointerException if the CacheClientNotifier instance is set
> ----------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: GEODE-7466
>                 URL: https://issues.apache.org/jira/browse/GEODE-7466
>             Project: Geode
>          Issue Type: Bug
>          Components: tests
>            Reporter: Barrett Oglesby
>            Priority: Major
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> Testing has shown this NPE can occur:
> {noformat}
> java.lang.NullPointerException
>     at java.util.concurrent.ConcurrentHashMap.get(ConcurrentHashMap.java:936)
>     at 
> org.apache.geode.internal.cache.tier.sockets.CacheClientNotifier.getClientProxy(CacheClientNotifier.java:1197)
>     at 
> org.apache.geode.internal.cache.ha.HARegionQueue$DispatchedAndCurrentEvents.putObject(HARegionQueue.java:3023)
>     at 
> org.apache.geode.internal.cache.ha.HARegionQueue.basicPut(HARegionQueue.java:679)
>     at 
> org.apache.geode.internal.cache.ha.HARegionQueue.put(HARegionQueue.java:631)
>     at 
> org.apache.geode.internal.cache.ha.HARegionQueueTest.queuePutElidesSequenceIdLowerThanOrEqualToLastSeenSequenceId(HARegionQueueTest.java:119)
> {noformat}
> HARegionQueue.java:3023 is here:
> {noformat}
>                             CacheClientNotifier ccn = 
> CacheClientNotifier.getInstance();
>                             if (ccn != null) {
> HARegionQueue.java:3023 ->    
> ccn.getClientProxy(owningQueue.clientProxyID).getStatistics().incMessagesFailedQueued();
>                             }
> {noformat}
> The HARegionQueueTest does not create a CacheClientNotifier, so it seems like 
> its created in another test and that test affects this one.
> If a CacheClientNotifier is created in this test, then the same NPE is thrown 
> because owningQueue.clientProxyID is null.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to