activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mtaylor <...@git.apache.org>
Subject [GitHub] activemq-artemis pull request #749: ARTEMIS-581 Implement max disk usage, an...
Date Mon, 05 Sep 2016 13:45:46 GMT
Github user mtaylor commented on a diff in the pull request:

    https://github.com/apache/activemq-artemis/pull/749#discussion_r77524240
  
    --- Diff: artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
---
    @@ -1249,6 +1256,14 @@ public RoutingStatus send(final ServerMessage message, final boolean
direct) thr
     
        @Override
        public RoutingStatus send(final ServerMessage message, final boolean direct, boolean
noAutoCreateQueue) throws Exception {
    +
    +      // If the protocol doesn't support flow control, we have no choice other than fail
the communication
    +      if (!this.getRemotingConnection().isSupportsFlowControl() && pagingManager.isDiskFull())
{
    +         ActiveMQIOErrorException exception = ActiveMQMessageBundle.BUNDLE.diskBeyondLimit();
    +         this.getRemotingConnection().fail(exception);
    +         throw exception;
    --- End diff --
    
    Why are these the only 2 solutions?  Surely we want to keep consumers alive so we can
gracefully recover from the situation?  
    
    Killing the connections could kill all the consumers too making it difficult to recover
once the memory and disk limit is reached.  DROP doesn't necessarily mean the messages are
lost, the client should choose an appropriate qos level and retry later.  Is it possible to
configure it to go from PAGING to DROP once the disk limit is reached?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message