mklaca commented on a change in pull request #76:
URL: https://github.com/apache/qpid-broker-j/pull/76#discussion_r595115906
##########
File path:
broker-core/src/main/java/org/apache/qpid/server/transport/AbstractAMQPConnection.java
##########
@@ -1161,28 +1161,35 @@ public void incrementTransactionBeginCounter()
}
@Override
- public void registered(final ConnectionPrincipalStatistics
connectionPrincipalStatistics)
+ public void freeConnectionSlots()
{
- _connectionPrincipalStatistics = connectionPrincipalStatistics;
+ ConnectionSlot slot;
+ while ((slot = _registeredConnectionSlots.poll()) != null)
+ {
+ slot.free();
+ }
}
@Override
- public int getAuthenticatedPrincipalConnectionCount()
+ public void addConnectionSlot(NamedAddressSpace addressSpace, String
userId)
{
- if (_connectionPrincipalStatistics == null)
- {
- return 0;
- }
- return _connectionPrincipalStatistics.getConnectionCount();
+ _registeredConnectionSlots.add(new ConnectionSlot(addressSpace,
userId));
}
- @Override
- public int getAuthenticatedPrincipalConnectionFrequency()
+ private final class ConnectionSlot
Review comment:
As per comments above a DeleteTask can not do the clean-up.
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]