[
https://issues.apache.org/jira/browse/QPID-8743?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18090836#comment-18090836
]
ASF GitHub Bot commented on QPID-8743:
--------------------------------------
vavrtom merged PR #400:
URL: https://github.com/apache/qpid-broker-j/pull/400
> [Broker-J] Add operation to close idle connections
> --------------------------------------------------
>
> Key: QPID-8743
> URL: https://issues.apache.org/jira/browse/QPID-8743
> Project: Qpid
> Issue Type: Improvement
> Components: Broker-J
> Affects Versions: qpid-java-broker-10.0.1
> Reporter: Daniil Kirilyuk
> Priority: Minor
> Fix For: qpid-java-broker-10.0.2
>
>
> QueueManagingVirtualHost API should be extended with the operation to close
> messaging connections idle for longer than the supplied interval.
> *Implementation*
> Added a broker REST endpoint:
> {code:java}
> POST /api/latest/virtualhost/<vh-node>/<vh>/closeIdleConnections
> { "idleTimeMillis": 300000, "waitForClose": "true | false", "timeoutMillis":
> 2000 } {code}
> It should close connections based on condition
> {code:java}
> System.currentTimeMillies() - connection.getLastMessageTime().getTime() >
> idleTimeMillies {code}
> Returned will be the list of closed connections:
> {code:java}
> {
> "matchedCount": 0,
> "closeRequestedCount": 0,
> "closedCount": 0,
> "failedCount": 0,
> "timeOutCount": 0,
> "connections": [{
> "id": "",
> "name": "",
> "remoteAddress": "",
> "principal": "".
> "lastMessageTime": "".
> "idleTimeMillies": "",
> "status": "CLOSE_REQUESTED | CLOSED | FAILED | TIMED_OUT"
> }]
> }{code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]