在WSO2 CEP 3.1.0中处理MQTT消息 [英] Handling MQTT messages in WSO2 CEP 3.1.0

查看:99
本文介绍了在WSO2 CEP 3.1.0中处理MQTT消息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个使用MQTT发布者的方案.

I have a scenario in which I have MQTT publisher.

MQTT客户端->消息代理-> WSO2 CEP(JMS输入适配器)

MQTT Client --> Message Broker --> WSO2 CEP (JMS input adaptor)

通过什么方式可以获取此已发布的MQTT消息作为WSO2 CEP的输入?

What are the ways by which I can get this published MQTT message as input to WSO2 CEP?

我尝试使用ActiveMQ作为消息代理和CEP JMS输入适配器来侦听JMS消息,但ActiveMQ会将MQTT消息转换为ByteMessage,我相信CEP到目前为止不会处理它,因为在同一设置中发布的JMS消息正在运行很好.
我知道WSO2 CEP 4.0.0具有MQTT输入适配器的功能.如何在CEP 3.1.0中处理它?<​​/p>

I tried using ActiveMQ as a message broker and a CEP JMS input adaptor listening to JMS message but ActiveMQ transforms MQTT message as ByteMessage, I believe CEP does not handles it as of now, as JMS messages published in the same setup is working fine.
I know WSO2 CEP 4.0.0 has a feature of MQTT input adaptor. How can I handle it in CEP 3.1.0?

推荐答案

是的,我们尚未在CEP 3.1.0中处理JMS输入事件适配器的ByteMessage方案.但是,我们已经在CEP 4.0.0(以及BAM 2.5.0发行的CEP功能)中修复了此问题

Yes, We haven't handled the ByteMessage scenario for JMS input event adapter in CEP 3.1.0. But, we have fixed this in CEP 4.0.0 (and in CEP features which released with BAM 2.5.0)

我想提供一些选项使其可以与CEP 3.1.0一起使用.正如Tharik提到的那样,MQTT输入事件适配器功能可从下一个CEP版本(4.0.0)中获得.以下是可能的选项.

I like to provide some options to make it work with CEP 3.1.0 .. As Tharik mentioned MQTT input event adapter feature is available from next CEP version (4.0.0). Below are the possible options.

1)您可以修补JMS输入事件适配器,并将其作为CEP服务器的补丁包括在内. (修复[1]中可用)

1) You can either patch the JMS input event adpter and include that as a patch for CEP server. (Fix is available in [1])

2)使用BAM 2.5.0中可用的MQTT输入事件适配器jar. (构建源文件[2],然后将jar复制到CEP的dropins文件夹中,然后按照[3]进行操作)

2) Use the MQTT input event adapter jars which available in BAM 2.5.0. (Build the source [2] and copy the jar to dropins folder of CEP and follow [3])

3)编写您自己的自定义MQTT输入事件适配器,如[4]所述

3) Write your own custom MQTT input event adapter as given in [4]

[1] [2] [3] https://docs.wso2.com/display/BAM250/Input + MQTT + Event + Adapter

[4] https://mohanadarshan.wordpress.com/2014/07/14/writing-custom-event-adaptors-in-wso2-cep-3-1-0/

谢谢..

这篇关于在WSO2 CEP 3.1.0中处理MQTT消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆