I don't recall any issues with BLOCK which we've fixed in 2.18.0 or 2.19.0
and all the tests are passing. It certainly could be a new bug, but we'd
need more details to confirm.

First off, what kind of client are you using to send the messages?


Justin

On Thu, Nov 18, 2021 at 8:58 AM Roberto <kopi...@yahoo.es.invalid> wrote:

> Hi all,
> In certain configurations the address-full-policy set to BLOCK does not
> work in Artemis 2.17.0.
> The following configuration:
>       <address-settings>
>          <address-setting match="events.inject">
>             <max-size-bytes>50Mb</max-size-bytes>
>             <address-full-policy>BLOCK</address-full-policy>
>          </address-setting>
>       </address-settings>
>       <addresses>
>          <address name="events.inject">
>             <anycast>
>                <queue name="events.inject">
>                </queue>
>             </anycast>
>          </address>
>       </addresses>
> This code never blocks events.inject and if you ingest faster than the
> consumer it grows until Artemis runs out of memory. It should grow until
> the 50 Megabytes are reached and then block until the queue is removed.
> According to
> https://activemq.apache.org/components/artemis/documentation/latest/paging.html
> it should block until there is space available.
> Setting the policy to PAGE or FAIL works plus sends a log when the limit
> is hit.
> Am I missing something or is it a bug in Artemis?
>
> Full configuration below:
> <?xml version='1.0'?>
> <configuration xmlns="urn:activemq"
>    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>    xmlns:xi="http://www.w3.org/2001/XInclude";
>    xsi:schemaLocation="urn:activemq /schema/artemis-configuration.xsd">
>    <core xmlns="urn:activemq:core"
>       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>       xsi:schemaLocation="urn:activemq:core ">
>       <name>artemis-ext (mpmt-gems-artemis-02)</name>
>       <persistence-enabled>true</persistence-enabled>
>       <journal-type>NIO</journal-type>
>       <paging-directory>data/paging</paging-directory>
>       <bindings-directory>data/bindings</bindings-directory>
>       <journal-directory>data/journal</journal-directory>
>
> <large-messages-directory>data/large-messages</large-messages-directory>
>       <global-max-size>400Mb</global-max-size>
>       <acceptors>
>          <acceptor name="artemis">tcp://
> 0.0.0.0:61616?tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576;protocols=CORE,AMQP,STOMP,HORNETQ,MQTT,OPENWIRE;useEpoll=true;amqpCredits=1000;amqpLowCredits=300;supportAdvisory=false;batchDelay=50;directDeliver=true;nioRemotingThreads=4
> </acceptor>
>       </acceptors>
>       <security-enabled>false</security-enabled>
>       <address-settings>
>          <address-setting match="events.inject">
>             <max-size-bytes>50Mb</max-size-bytes>
>             <address-full-policy>BLOCK</address-full-policy>
>          </address-setting>
>       </address-settings>
>       <addresses>
>          <address name="events.inject">
>             <anycast>
>                <queue name="events.inject">
>                </queue>
>             </anycast>
>          </address>
>       </addresses>
>    </core>
> </configuration>
>
>

Reply via email to