activemq

Spring boot - sharing embedded JMS broker with separate service

本秂侑毒 提交于 2019-12-02 03:17:12
问题 I have two services which should communicate with each other via ActiveMQ. Everything works nicely when I have the receiver and sender in one service but when I split them, I got a strange activemq exception. This is configuration of service A: @EnableScheduling @SpringBootApplication @EnableJms public class App extends SpringBootServletInitializer { private static final Logger log = LoggerFactory.getLogger(App.class); @Autowired private static JmsTemplate jms; public static void main(String[

ActiveMQ 5.11 with WebSphere Application Server 8.5

≡放荡痞女 提交于 2019-12-02 02:28:08
Does anybody know which jars from ActiveMQ 5.11 I need to use with IBM Websphere Application Server 8.5 in order to create a new ActiveMQ JMS Provider? I found discussions related to older ActiveMQ versions that don't seem applicable anymore because the way ActiveMQ is packaged has changed: https://www.ibm.com/developerworks/community/blogs/timdp/entry/using_activemq_as_a_jms_provider_in_websphere_application_server_7149?lang=en ActiveMQ 5.11 doesn't seem to have activemq-core anymore, activeio-core is under "optional", and ActiveMQ seems to have switched from commons-logging to slf4j, which

Is it possible to have dead letter queue for individual queues

心已入冬 提交于 2019-12-02 01:06:44
问题 I currently have a Queue in my ActiveMQ server called hello.world . Whenever a message fails to be processed, ActiveMQ creates a default directory called ActiveMQ.DLQ . Is it possible to change that name to something like hello.world.DLQ ? The reason being is that I might have several queues in the future and I want it to be something like <queue_name>.DLQ 回答1: The thing you are looking for is called Individual Dead letter Queue strategy , in this process ActiveMQ creates specific DLQ for

JMS Bridge Between WildFly 10 Artemis and ActiveMQ 5.14 (ONCE_AND_ONLY_ONCE Quality of Service)

好久不见. 提交于 2019-12-02 01:01:19
I'm trying to set up a JMS Bridge between Artemis (Running in WildFly 10) and ActiveMQ 5.14 In general the process seems to work smoothly, but unfortunately I'm getting stuck on the XA configuration that is necessary to get ONCE_AND_ONLY_ONCE QoS to work. Although messages do arrive on the ActiveMQ side, I get the following error in the WildFly log: 11:25:57,920 WARN [org.apache.activemq.artemis.jms.bridge] (Thread-97) AMQ342009: JMS Bridge failed to send + acknowledge batch, closing JMS objects: javax.jms.IllegalStateException: Not a transacted session at org.apache.activemq.ActiveMQSession

activeMQ5官方文档翻译-初始化配置

给你一囗甜甜゛ 提交于 2019-12-02 00:40:37
首先你需要把jar包加到classpath 所需的jar包 为了使ActiveMQ更容易使用,默认的 activemq-all.jar包 包含了所有需要用到的库文件。如果你喜欢以明确的控制jar包的方式来使用 ActiveMQ,那下面是每个需要用到的jar包的列表: activemq-broker.jar activemq-client.jar activemq-kahadb-store.jar activemq-spring.jar slf4j-api.jar slf4j-log4j12.jar log4j-1.2.17.jar J2EE APIs: 可以从sun公司(现在应该是oracle公司)下载j2ee.jar,也可以从你的j2ee容器中去获取或者你也可以使用apache Geronimoe服务器以自由软件的方式发布的geronimo-spec-j2ee.jar。If you are inside a servlet container and being dependent on the j2ee.jar causes you troubles,我们依赖到的j2ee相关的jar包如下: geronimo-spec-jms.jar geronimo-spec-jta.jar geronimo-spec-j2ee-management.jar

Is it possible to connect to spring boot embedded ActiveMQ instance from another application(started in separate process)?

倾然丶 夕夏残阳落幕 提交于 2019-12-02 00:30:57
问题 I've read several examples about jms support in spring boot. and usually sender, receiver and active-mq(actually it can be any other jms compatible message broker) locates within the same application. I know that I can use stand alone active mq and use properties: spring.activemq.broker-url=tcp://192.168.1.210:9876 spring.activemq.user=admin spring.activemq.password=secret But I want to have 2 applications: 1- sender (connects to jms from receiver embedded and sends messages there) 2-receiver

activemq 的延迟队列和幂等性检查

六眼飞鱼酱① 提交于 2019-12-01 20:52:38
一. 延迟消息队列 1. 在提交支付之后,可以发送一个延迟检查的队列,来主动查询用户在支付宝上的支付状态 在 mq 的配置 /config/ activeMq.xml 的 broker 实例上配置 schedulerSupport="true" 2 延迟检查如果失败,则从新发送新的检查队列,并且要将检查次数减一 // 没有支付,再次发送检查队列 System. out .println( " 订单号: " +out_trade_no+ " 尚未支付成功,再次发送检查队列,剩余检查次数: " +count); if (count>0){ System. out .println( " 订单号: " +out_trade_no+ " 检查次数尚未用尽,再次发送检查队列 " +count); count --; paymentService .sendDelayPaymentCheckQueue(out_trade_no,count); } else { System. out .println( " 订单号: " +out_trade_no+ " 检查次数耗尽,停止检查,调用关单服务 " ); } 二. 幂等性检查 调用相同的服务,返回的结果始终一样,叫做幂等性检查. 例子: 第一步,在支付的controller层发起延迟队列 @RequestMapping("/alipay

技术大牛分享:JAVA学习路线

旧街凉风 提交于 2019-12-01 20:32:50
01 Java 开发介绍 - DOS 常用命令 - JVM 、 JRE 、 JDK 之间的关系 - Java 开发环境的搭建:安装 JDK ,配置环境变量 - JDK 中常用的工具(编译,执行) - Java 入门程序( Java 的开发流程) - Java 的注释 - 标识符、标识符的命名规范 - Java 关键字 - Java 基本数据类型 - Java 基本类型之间的相互转换 - 变量和常量的定义及初始化 - 变量的分类 - Java 的运算符 - 表达式 - 转义字符 - 运算符的优先级 - Java 分支语句之 if...else - 多重 if...else 、嵌套 if...else - Java 分支语句之 switch-case 结构 - switch 与 if 的区别 - Java 循环 for 、 while 、 do...while - 循环的嵌套 - break 、 continue 的使用以及区别 - 方法的定义 - 方法的形参和实参 - 无返回值的方法 - 有返回值的方法 - return 语句的使用 - 方法的调用 - 方法的压栈 - 方法的重载 - 方法的递归调用 02 数组 - Java 数组的定义 - Java 数组的声明 - 数组的优势与局限 - 数组的静态初始化 - 数组的动态初始化 - 数组的存储特点(堆和栈) - 数组单个元素的访问 -

ActiveMQ throttling consumer

馋奶兔 提交于 2019-12-01 19:53:04
i want to do a throttling to a consumer of some queue in the activeMQ, in hornetq (of jboss, this is do it with annotations on the definition of the mdb Consumer). I can't find any similar in the documentation of activemq, the closest that i find was this consumer.recvDelay 0 ms Pause consumer for recvDelay milliseconds with each message (allows consumer throttling). from: http://activemq.apache.org/activemq-performance-module-users-manual.html But there i can't find how i can do it in java. Thanks in advance, Regards. EDIT: Here is the ActiveMQManager code and the consumer code: public class

ActiveMQ JMS ping

≡放荡痞女 提交于 2019-12-01 17:20:17
Apache Activemq 5.2.0 My application listens to messages on three topics and sends messages on 2 topics. When my application is "webping"ed, I want to check if these topics are alive. I would like to know if this is possible. Here are my observations, Advisory messages can be used for this, but they send messages only when a producer/consumer joins. This is not quite what I want. I just want to check if I can send messages to outbound topics and can receive messages on the inbound topic. Custom Heartbeat solution. I can make every producer send a heartbeat message say every 5 seconds and the