这是我的ejb-jar.xml
:
<ejb-jar version="3.0">
<enterprise-beans>
<message-driven>
<ejb-name>myMDB</ejb-name>
<activation-config>
<activation-config-property>
<activation-config-property-name>destinationType
</activation-config-property-name>
<activation-config-property-value>javax.jms.Queue
</activation-config-property-value>
</activation-config-property>
<activation-config-property>
<activation-config-property-name>destination
</activation-config-property-name>
<activation-config-property-value>queue/test
</activation-config-property-value>
</activation-config-property>
<activation-config-property>
<activation-config-property-name>connectionParameters
</activation-config-property-name>
<activation-config-property-value>host=localhost;port=5445
</activation-config-property-value>
</activation-config-property>
<activation-config-property>
<activation-config-property-name>username
</activation-config-property-name>
<activation-config-property-value>xxx
</activation-config-property-value>
</activation-config-property>
<activation-config-property>
<activation-config-property-name>password
</activation-config-property-name>
<activation-config-property-value>yyy
</activation-config-property-value>
</activation-config-property>
</activation-config>
</message-driven>
</enterprise-beans>
</ejb-jar>
我不明白为什么会收到此警告:
ActivationConfigProperty username will be ignored since it is not allowed by resource adapter: hornetq-ra
我也试过userName
和UserName
,但我总是得到同样的警告。
我应该配置任何ra.xml文件吗?
感谢您的帮助。
备注:我使用JBoss AS 7.2
答案 0 :(得分:0)
JBoss无法识别属性“username”。将其更改为“用户”,它应该好好接受它。作为参考,这里是一个JBoss寻找的列表,就ActivationConfigProperties而言:
https://docs.jboss.org/ejb3/docs/tutorial/1.0.7/html/Message_Driven_Beans.html