Barrett Oglesby created GEODE-9620:
--------------------------------------

             Summary: The CacheServerStats currentQueueConnections statistic is 
incremented and decremented twice per client queue
                 Key: GEODE-9620
                 URL: https://issues.apache.org/jira/browse/GEODE-9620
             Project: Geode
          Issue Type: Bug
          Components: client queues
            Reporter: Barrett Oglesby


The CacheServerStats currentQueueConnections statistic is incremented and 
decremented twice per client queue

When a client with subscription enabled joins connects to the server, the 
CacheServerStats currentQueueConnections statistic is incremented twice.

Once by the ServerConnection thread here:
{noformat}
[warn 2021/09/21 11:22:18.851 PDT server-1 <ServerConnection on port 63920 
Thread 1> tid=0x41] XXX CacheServerStats.incCurrentQueueConnections 
currentQueueConnectionsId=1
java.lang.Exception
        at 
org.apache.geode.internal.cache.tier.sockets.CacheServerStats.incCurrentQueueConnections(CacheServerStats.java:660)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.handshakeAccepted(ServerConnection.java:705)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.acceptHandShake(ServerConnection.java:682)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.processHandShake(ServerConnection.java:613)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.verifyClientConnection(ServerConnection.java:404)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.doHandshake(ServerConnection.java:787)
{noformat}
And once by the Client Queue Initialization Thread here:
{noformat}
[warn 2021/09/21 11:22:18.884 PDT server-1 <Client Queue Initialization Thread 
1> tid=0x44] XXX CacheServerStats.incCurrentQueueConnections 
currentQueueConnectionsId=2
java.lang.Exception
        at 
org.apache.geode.internal.cache.tier.sockets.CacheServerStats.incCurrentQueueConnections(CacheServerStats.java:660)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientProxy.<init>(CacheClientProxy.java:342)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientProxy.<init>(CacheClientProxy.java:306)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientNotifier.registerClientInternal(CacheClientNotifier.java:379)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientNotifier.registerClient(CacheClientNotifier.java:198)
        at 
org.apache.geode.internal.cache.tier.sockets.AcceptorImpl$ClientQueueInitializerTask.run(AcceptorImpl.java:1896)
{noformat}
When the client disconnects from the server, the CacheServerStats 
currentQueueConnections statistic is decremented twice.

Once by the ServerConnection thread here:
{noformat}
[warn 2021/09/21 11:24:01.129 PDT server-1 <ServerConnection on port 63920 
Thread 1> tid=0x41] XXX CacheServerStats.decCurrentQueueConnections 
currentQueueConnectionsId=1
java.lang.Exception
        at 
org.apache.geode.internal.cache.tier.sockets.CacheServerStats.decCurrentQueueConnections(CacheServerStats.java:665)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.handleTermination(ServerConnection.java:956)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.handleTermination(ServerConnection.java:929)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.run(ServerConnection.java:1289)
{noformat}
And once by a different ServerConnection thread here:
{noformat}
[warn 2021/09/21 11:24:01.135 PDT server-1 <ServerConnection on port 63920 
Thread 2> tid=0x42] XXX CacheServerStats.decCurrentQueueConnections 
currentQueueConnectionsId=0
java.lang.Exception
        at 
org.apache.geode.internal.cache.tier.sockets.CacheServerStats.decCurrentQueueConnections(CacheServerStats.java:665)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientProxy.closeSocket(CacheClientProxy.java:939)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientProxy.terminateDispatching(CacheClientProxy.java:895)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientProxy.close(CacheClientProxy.java:773)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientNotifier.closeDeadProxies(CacheClientNotifier.java:1558)
        at 
org.apache.geode.internal.cache.tier.sockets.CacheClientNotifier.unregisterClient(CacheClientNotifier.java:572)
        at 
org.apache.geode.internal.cache.tier.sockets.ClientHealthMonitor.unregisterClient(ClientHealthMonitor.java:268)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.handleTermination(ServerConnection.java:1008)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.handleTermination(ServerConnection.java:929)
        at 
org.apache.geode.internal.cache.tier.sockets.ServerConnection.run(ServerConnection.java:1289)
{noformat}




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

Reply via email to