简体   繁体   English

无法使STOMP受体在Wildfly Swarm中运行

[英]cannot get STOMP acceptor running in Wildfly Swarm

I'm trying to set up a STOMP acceptor in my Wildfly 11 based Swarm deployment (using Swarm 2017.12.1 to generate a fat WAR, running via java -jar... ), for letting clients send me progress messages, but could not get the acceptor to load, always get this error at server startup: 我试图在基于Wildfly 11的Swarm部署中设置STOMP接收器(使用Swarm 2017.12.1生成胖WAR,通过java -jar...运行),以便让客户端向我发送进度消息,但无法获取接受器,总是在服务器启动时得到此错误:

AMQ222203: Classpath lacks a protocol-manager for protocol STOMP, Protocol being ignored on acceptor TransportConfiguration(name=stomp-acceptor, factory=org-apache-activemq-artemis-core-remoting-impl-netty-NettyAcceptorFactory) ?port=61613&protocols=STOMP AMQ222203:类路径缺少协议STOMP的协议管理器,协议在接受方TransportConfiguration上被忽略(名称= stomp-acceptor,factory = org-apache-activemq-artemis-core-remoting-impl-netty-Netty-NettyAcceptorFactory)?port = 61613&protocols =脚踩

I am using an existing (but adapted) standalone-full.xml configuration to make the switch easier, and everything works fine so far (Java EE wise), but not the STOMP part (JMS works, though). 我正在使用一个现有的(但经过改编的) standalone-full.xml配置来standalone-full.xml切换,并且到目前为止一切正常(在Java EE方面),但是在STOMP部分却没有(JMS可以运行)。

I've included some dependencies in the WAR's POM to fix previous class loading errors, but now I run out of ideas: 我在WAR的POM中包含了一些依赖项,以解决以前的类加载错误,但是现在我的想法不多了:

<dependency>
  <groupid>org.apache.activemq</groupid>
  <artifactid>activemq-rar</artifactid>
  <version>5.15.2</version>
  <type>rar</type>
</dependency>
<dependency>
  <groupid>org.apache.activemq</groupid>
  <artifactid>activemq-stomp</artifactid>
  <version>5.15.2</version>
</dependency>
<dependency>
  <groupid>io.netty</groupid>
  <artifactid>netty-all</artifactid>
  <version>4.1.5.Final</version>
</dependency>

(so I'm relying on Swarm to figure out needed fragments, which works for the rest) (所以我依靠Swarm找出所需的片段,其余片段都可以使用)

My configuration for the messaging part looks like this: 我对消息传递部分的配置如下所示:

<acceptor name="stomp-acceptor" factory-class="org.apache.activemq.artemis.core.remoting.impl.netty.NettyAcceptorFactory">
    <param name="protocols" value="STOMP"/>
    <!--param name="connection-ttl" value="30000"/-->
    <param name="host" value="${jboss.bind.address:127.0.0.1}"/>
    <param name="port" value="61613"/>
    <!--param name="stomp-enable-message-id" value="true"/-->
</acceptor>

I've searched Swarm, Artemis and also SO but didn't find a working solution. 我搜索了Swarm,Artemis和SO,但没有找到可行的解决方案。 Could it be that Wildfly 11 will not work since it's using Artemis 1.5 and Swarm does not yet fully support it? 难道是因为Wildfly 11使用的是Artemis 1.5而Swarm尚未完全支持它,所以它无法正常工作?

some resources I found useful so far: 到目前为止,我发现有用的一些资源:

A friendly and helpful chat on #wildfly-swarm brought an explanation and possible solution, but we'll have to wait for the bugfix, see https://issues.jboss.org/browse/SWARM-1763 在#wildfly-swarm上进行的友好而有益的交谈带来了解释和可能的解决方案,但我们必须等待错误修正,请参阅https://issues.jboss.org/browse/SWARM-1763

Ken Finnigan found out the root cause in an error in the modules configuration for messaging in Wildfly: Ken Finnigan找出了Wildfly中用于消息传递的模块配置错误的根本原因:

The issue is a result of the org.apache.activemq.artemis module.xml defining protocol modules for STOMP, AMQP and HornetQ as optional, so WF Swarm does not pick them up. 该问题是由于org.apache.activemq.artemis module.xml将STOMP,AMQP和HornetQ的协议模块定义为可选的,因此WF Swarm不会选择它们。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM