activemq-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ARTEMIS-1924) Adding the possibility of configure AMQP IdleTimeout
Date Mon, 11 Jun 2018 22:41:00 GMT

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

ASF GitHub Bot commented on ARTEMIS-1924:
-----------------------------------------

Github user clebertsuconic commented on a diff in the pull request:

    https://github.com/apache/activemq-artemis/pull/2135#discussion_r194569421
  
    --- Diff: tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/amqp/AmqpNoHearbeatsTest.java
---
    @@ -0,0 +1,83 @@
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *      http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +package org.apache.activemq.artemis.tests.integration.amqp;
    +
    +import java.util.Arrays;
    +import java.util.Collection;
    +import java.util.Map;
    +
    +import org.apache.activemq.artemis.core.server.ActiveMQServer;
    +import org.apache.activemq.transport.amqp.client.AmqpClient;
    +import org.apache.activemq.transport.amqp.client.AmqpConnection;
    +import org.apache.activemq.transport.amqp.client.AmqpValidator;
    +import org.apache.qpid.proton.engine.Connection;
    +import org.junit.Test;
    +import org.junit.runner.RunWith;
    +import org.junit.runners.Parameterized;
    +
    +@RunWith(Parameterized.class)
    +public class AmqpNoHearbeatsTest extends AmqpClientTestSupport {
    +
    +   @Parameterized.Parameters(name = "useOverride={0}")
    +   public static Collection<Object[]> parameters() {
    +      return Arrays.asList(new Object[][] {
    +         {true}, {false}
    +      });
    +   }
    +
    +   @Parameterized.Parameter(0)
    +   public boolean useOverride;
    +
    +   @Override
    +   protected void addConfiguration(ActiveMQServer server) {
    +      if (useOverride) {
    +         server.getConfiguration().setConnectionTTLOverride(0);
    +      } else {
    +         server.getConfiguration().setConnectionTtlCheckInterval(500);
    +      }
    +   }
    +
    +
    +   @Override
    +   protected void configureAMQPAcceptorParameters(Map<String, Object> params) {
    +      if (!useOverride) {
    +         params.put("amqpIdleTimeout", "0");
    +      }
    +   }
    +
    +
    +   @Test(timeout = 60000)
    +   public void testBrokerSendsHalfConfiguredIdleTimeout() throws Exception {
    --- End diff --
    
    ouch.. you're right.. and I missed it.. I will rename right away.
    
    
    the joy of copy & paste


> Adding the possibility of configure AMQP IdleTimeout
> ----------------------------------------------------
>
>                 Key: ARTEMIS-1924
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-1924
>             Project: ActiveMQ Artemis
>          Issue Type: Improvement
>            Reporter: clebert suconic
>            Assignee: clebert suconic
>            Priority: Major
>
> connection Timeout Override was meant to bypass client behavior on core protocol, not
to specify the TTL on AMQP connections or server based protocols.
>  
> the server will send a TTL to the client, so it should be possible to pass 0 and disable
TTL.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message