As there seems to be a basic incompatibility with version 4.2.0 connecting to a message
queue hosted on legacy version 3.0.3 (issue posted on the JNDI board), I thought I'd
just move the legacy app containing the message bean to version 4.2.0. In theory I should
just be able to take the .jar file containing the message bean and deploy it. No special
configuration required as the legacy app uses "queue/testQueue".
After fixing an ejb-jar.xml issue that 3.0.3 didn't have a problem with, I now get
this error on 4.2.0:
13:57:43,375 WARN [verifier] EJB spec violation:
| Bean : AutoCreditMessageBean
| Section: 15.7.2
| Warning: A message driven bean must implement, directly or indirectly, the message
listener class
But it does:
public class AutoCreditMessageBean implements javax.ejb.MessageDrivenBean,
javax.jms.MessageListener
| {
| ...
| }
And the deployment descriptor specifies it.
ejb-jar.xml:
<?xml version="1.0" encoding="UTF-8"?>
| <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
|
| <ejb-jar>
| <enterprise-beans>
| <message-driven>
|
| <ejb-name>AutoCreditMessageBean</ejb-name>
| <ejb-class>org.myorg.AutoCreditMessageBean</ejb-class>
|
| <transaction-type>Container</transaction-type>
| <message-selector>messageType = 'request'</message-selector>
| <messaging-type>javax.jms.MessageListener</messaging-type>
|
| <acknowledge-mode>Auto-acknowledge</acknowledge-mode>
|
| <message-driven-destination>
| <destination-type>javax.jms.Queue</destination-type>
| </message-driven-destination>
|
| </message-driven>
|
| </enterprise-beans>
|
| <assembly-descriptor>
| </assembly-descriptor>
|
| </ejb-jar>
jboss.xml:
<?xml version="1.0" encoding="UTF-8"?>
|
| <jboss>
|
| <secure>false</secure>
|
| <container-configurations />
|
| <resource-managers />
|
| <enterprise-beans>
|
| <message-driven>
| <ejb-name>AutoCreditMessageBean</ejb-name>
| <destination-jndi-name>queue/testQueue</destination-jndi-name>
| </message-driven>
|
| </enterprise-beans>
| </jboss>
Any thoughts? Or do I have to rewrite this to EJB3?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4146620#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...