【问题标题】:Started paging before reaching max size in ActiveMQ Artemis在 ActiveMQ Artemis 中达到最大大小之前开始分页
【发布时间】:2021-06-20 11:52:04
【问题描述】:

在达到 ActiveMQ Artemis 2.17.0 版本中配置的最大大小之前开始分页。

2021-05-31 08:59:30,293 WARN  [org.apache.activemq.artemis.core.server] AMQ222038: Starting paging on address 'consumer_queue'; size is currently: 208,250 bytes; max-size-bytes: 524,288,000; global-size-bytes: 1,073,744,320

为队列consumer_queue配置的地址设置。

<address-setting match="consumer_queue">
    <dead-letter-address>DLQ</dead-letter-address>
    <expiry-address>ExpiryQueue</expiry-address>
    <redelivery-delay>0</redelivery-delay>
    <max-size-bytes>500Mb</max-size-bytes>
    <page-size-bytes>10Mb</page-size-bytes>
    <max-delivery-attempts>5</max-delivery-attempts>
    <message-counter-history-day-limit>10</message-counter-history-day-limit>
    <address-full-policy>PAGE</address-full-policy>
    <auto-create-queues>false</auto-create-queues>
    <auto-create-addresses>false</auto-create-addresses>
    <auto-create-jms-queues>false</auto-create-jms-queues>
    <auto-create-jms-topics>false</auto-create-jms-topics>
</address-setting>

global-max-size 设置为-1。 JVM 使用-Xms36G,broker 自动将global-max-size 配置为18G,通过此日志确认:

AMQ221057: Global Max Size is being adjusted to 1/2 of the JVM max size (-Xmx). being defined as 19,327,352,832

【问题讨论】:

    标签: activemq-artemis


    【解决方案1】:

    这看起来可能是一个错误。请提交问题here,并附上一个可重现的最小示例。

    【讨论】:

    • 实际配置的堆大小为36G 考虑到应用程序量和流量。此外,我设置了每个特定地址的最大内存,并期望在达到该配置值后开始分页。大多数情况下,当分页开始时,我注意到当前大小和最大大小几乎相同。
    • 您能否通过检查我在回答中引用的日志记录来验证 global-max-size 的设置是否符合您的预期?
    • 在 Artemis 启动期间,发现以下行 AMQ221057: Global Max Size is being adjusted to 1/2 of the JVM max size (-Xmx). being defined as 19,327,352,832 。这意味着 19Gb。
    • 明确一点,19,327,352,832 实际上是 18GB(即 18 * 1024 * 1024 * 1024)。
    • 我已根据您提供的所有新信息更新了我的答案。
    猜你喜欢
    • 2020-01-06
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-04-02
    • 1970-01-01
    • 2022-09-28
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多