最近ActiveMQ 5.15.3 会报 OutofMemory的错误

在 wrapper.conf中

#wrapper.java.additional.8=-Dorg.apache.activemq.UseDedicatedTaskRunner=true
wrapper.java.additional.8=-Dorg.apache.activemq.UseDedicatedTaskRunner=false
#加入新的一句
wrapper.java.additional.13=-Xms2G -Xmx2G -Xss512K

  activemq.xml里修改

<!--Licensed to the Apache Software Foundation (ASF) under one or morecontributor license agreements.  See the NOTICE file distributed withthis 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 withthe License.  You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0Unless required by applicable law or agreed to in writing, softwaredistributed 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 andlimitations under the License.
-->
<!-- START SNIPPET: example -->
<beansxmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsdhttp://activemq.apache.org/schema/core http://activemq.apache.org/schema/core/activemq-core.xsd"><!-- Allows us to use system properties as variables in this configuration file --><bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"><property name="locations"><value>file:${activemq.conf}/credentials.properties</value></property></bean><!-- Allows accessing the server log --><bean id="logQuery" class="io.fabric8.insight.log.log4j.Log4jLogQuery"lazy-init="false" scope="singleton"init-method="start" destroy-method="stop"></bean><!--The <broker> element is used to configure the ActiveMQ broker.--><broker xmlns="http://activemq.apache.org/schema/core" brokerName="localhost" dataDirectory="${activemq.data}"><destinationPolicy><policyMap><policyEntries><policyEntry topic=">" producerFlowControl="true"><!-- The constantPendingMessageLimitStrategy is used to preventslow topic consumers to block producers and affect other consumersby limiting the number of messages that are retainedFor more information, see:http://activemq.apache.org/slow-consumer-handling.html--><pendingMessageLimitStrategy><constantPendingMessageLimitStrategy limit="1000"/></pendingMessageLimitStrategy></policyEntry><policyEntry queue=">" producerFlowControl="false" memoryLimit="20mb" >  <!-- Use VM cursor for better latency  For more information, see:  http://activemq.apache.org/message-cursors.html  <pendingQueuePolicy>  <vmQueueCursor/>  </pendingQueuePolicy>  -->  </policyEntry>  </policyEntries></policyMap></destinationPolicy><!--The managementContext is used to configure how ActiveMQ is exposed inJMX. By default, ActiveMQ uses the MBean server that is started bythe JVM. For more information, see:http://activemq.apache.org/jmx.html--><managementContext><managementContext createConnector="false"/></managementContext><!--Configure message persistence for the broker. The default persistencemechanism is the KahaDB store (identified by the kahaDB tag).For more information, see:http://activemq.apache.org/persistence.html--><persistenceAdapter><!--<kahaDB directory="${activemq.data}/kahadb"/>--><kahaDB directory="${activemq.data}/kahadb" enableIndexWriteAsync="true"  enableJournalDiskSyncs="false"/></persistenceAdapter><!--The systemUsage controls the maximum amount of space the broker willuse before disabling caching and/or slowing down producers. For more information, see:http://activemq.apache.org/producer-flow-control.html<systemUsage><systemUsage><memoryUsage><memoryUsage percentOfJvmHeap="70" /></memoryUsage><storeUsage><storeUsage limit="100 gb"/></storeUsage><tempUsage><tempUsage limit="50 gb"/></tempUsage></systemUsage></systemUsage>
--><systemUsage>  <systemUsage>  <memoryUsage>  <memoryUsage limit="1400 mb"/>  </memoryUsage>  <storeUsage>  <storeUsage limit="100 gb"/>  </storeUsage>  <tempUsage>  <tempUsage limit="50 gb"/>  </tempUsage>  </systemUsage>  </systemUsage>  <!--The transport connectors expose ActiveMQ over a given protocol toclients and other brokers. For more information, see:http://activemq.apache.org/configuring-transports.html--><transportConnectors><!-- DOS protection, limit concurrent connections to 1000 and frame size to 100MB --><transportConnector name="openwire" uri="tcp://0.0.0.0:61616?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/><transportConnector name="amqp" uri="amqp://0.0.0.0:5672?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/><transportConnector name="stomp" uri="stomp://0.0.0.0:61613?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/><transportConnector name="mqtt" uri="mqtt://0.0.0.0:1883?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/><transportConnector name="ws" uri="ws://0.0.0.0:61614?maximumConnections=1000&amp;wireFormat.maxFrameSize=104857600"/></transportConnectors><!-- destroy the spring context on shutdown to stop jetty --><shutdownHooks><bean xmlns="http://www.springframework.org/schema/beans" class="org.apache.activemq.hooks.SpringContextHook" /></shutdownHooks></broker><!--Enable web consoles, REST and Ajax APIs and demosThe web consoles requires by default login, you can disable this in the jetty.xml fileTake a look at ${ACTIVEMQ_HOME}/conf/jetty.xml for more details--><import resource="jetty.xml"/></beans>
<!-- END SNIPPET: example -->

转载于:https://www.cnblogs.com/wingfay/p/8990371.html

ActiveMq Windows 配置优化相关推荐

  1. java环境变量设置优化_Mac/windows配置jdk环境变量-seo优化只选拉一八科技

    Mac/windows配置jdk环境变量 Mac配置jdk环境变量 直接双击dmg文件,然后单击[下一步]完成安装.请忽略[配置jdk环境变量]直接跳转到[检查jdk是否安装成功]. Windows配 ...

  2. MySQL 5.6 my.cnf配置优化

    MySQL 5.6 my.cnf配置优化 4核 16G Centos6.5 x64 优化后测试结果如下 #mysqlslap #--concurrency=2 #--iterations=1 #--n ...

  3. Redis在Linux系统的配置优化

    通常来看,Redis开发和运维人员更加关注的是Redis本身的一些配置优化,例如AOF和RDB的配置优化.数据结构的配置优化等,但是对于操作系统是否需要针对Redis做一些配置优化不甚了解或者不太关心 ...

  4. activemq主从配置_使用ActiveMQ –具有故障转移协议的“主/从”配置

    activemq主从配置 介绍 ActiveMQ代理往往是企业中消息传递基础结构的核心部分. 此消息传递基础结构的高度可用性和可伸缩性至关重要. 请阅读此链接 ,以了解有关创建经纪人网络以支持各种用例 ...

  5. Advanced SystemCare Pro 中文绿色特别便携正式版一款易于使用的 Windows 电脑优化工具

    Advanced SystemCare Pro 中文绿色特别便携正式版 是 IObit 公司开发的一款易于使用的 Windows 电脑优化工具,是难得一见的高性能优化工具.它能对系统进行全面的诊断,在 ...

  6. Android Studio配置优化最全详解

    适合第一次安装AS的新手,感谢网上的资源 是不是很多同学已经有烦恼出现了?电脑配置已经很高了,但是每次运行Android程序的时候就很卡,而且每次安装运行程序都要等待很长时间,如果是在开发后期需要不停 ...

  7. IDEA配置优化,idea配置大全

    IDEA 配置优化32招 1.设置 Maven 1.在File->settings->搜索maven 2.Mavan home directory--设置maven安装包的bin文件夹所在 ...

  8. win2008安装 配置 优化终极攻略

    MS公布了全新SERVER OS 2008以来,反响强烈.经过在下亲自使用过后感觉不错,现将自己的心得体会整理后发表出来供大家参考. 安装WINDOWS SERVER 2008前请确认你已经做好了以下 ...

  9. 如何启动和退出w8ndows,Windows 8优化设置技巧,加快你的win8运行速度

    Windows 8优化设置技巧,加快你的win8运行速度 书法字体2013.03.19win8优化 收集的实用Windows 8优化技巧,告诉你如何加快你的win8运行速度.虽然已经有越来越多的用户已 ...

最新文章

  1. Can't connect to local MySQL Server throught socket '/var/run/mysqld/mysqld.sock'(2)
  2. va_list/va_start/va_end的使用
  3. 央视曝光紫砂锅名单_大家看今天中午《每周质量报告》没,美的牌 紫砂锅含有剧毒。家里有这牌子...
  4. 连接postgresql
  5. P2转P3时出现‘utf-8‘ codec can‘t decode byte 0xb3 in position 0: invalid start byte(\x、decode解码)
  6. 如何在CentOS 7上安装和配置MySQL Cluster
  7. java基础—文件的切割与合并
  8. php 判断赋值 简写,PHP IF 判断简写
  9. TagSupport标签的应用
  10. linux less命令详解
  11. 网络爬虫的基本原理(一)
  12. atitit..代码生成流程图 流程图绘制解决方案 java  c#.net  php v2
  13. 用C语言实现万年历的代码及思路(详细教程)
  14. 室内定位之蓝牙定位精度(蓝牙AOA定位)
  15. 基于python+django框架+Mysql数据库的疫苗预约系统设计与实现
  16. 种子软件下载种子慢怎么解决
  17. 我用AI生成了这些明星一生的样貌变化 | 已填坑附源码
  18. 谷歌雅虎将联手实行即时信息兼容性计划
  19. [从头读历史] 第249节 易经
  20. pandas使用read_csv函数读取文件的前N行数据并保留表头、pandas使用read_csv函数读取制表符分割的文件(tab-delimited)、自定义设置sep参数

热门文章

  1. ruby与python_Ruby对比Python的优势和劣势
  2. mysql mask from v2_MySQLDMB监控备份系统更新至v2.2
  3. 医学图像处理期末复习(三)
  4. 学python对数学要求高吗_人工智能的小男孩 大专学历的人没有数学基础想学习python技术未来能往大数据或人工智能方向进行职业发展吗?...
  5. uwsgi指定python路径_uwsgi-安装实操
  6. linux mint 18 mysql_linux mint下mysql中文支持问题
  7. 提高vivado的编译速度
  8. 电脑手写输入法_QQ拼音输入法除了能打字,竟然还有 N 多妙用!
  9. arcgis使用工具箱导出dbf_ArcGIS——好好的属性表,咋就乱码了呢?
  10. 树莓派kail linux安装wine,在ubuntu14.04中安装wine