Discussion:
[jboss-user] [IronJacamar] - Hello World Example
daedlus D
2013-04-09 09:05:51 UTC
Permalink
daedlus D [https://community.jboss.org/people/daedlus] created the discussion

"Hello World Example"

To view the discussion, visit: https://community.jboss.org/message/807155#807155

--------------------------------------------------------------
Hi ,
i have deployed the hello world rar example and i see the HelloWorldManagedConnectionFactory binded to jndi and is available using name
h6. java:/eis/HelloWorld


I have a simple ejb bean in which i look up this using below code:


h6. @Resource(mappedName = "java:/eis/HelloWorld")

   private HelloWorldConnectionFactory connectionFactory;


i get below error


| | Caused by: javax.ejb.EJBException: java.lang.ClassCastException: org.jboss.jca.samples.helloworld.HelloWorldConnectionFactoryImpl cannot be cast to org.jboss.jca.samples.helloworld.HelloWorldConnectionFactory |
| | Caused by: java.lang.ClassCastException: org.jboss.jca.samples.helloworld.HelloWorldConnectionFactoryImpl cannot be cast to org.jboss.jca.samples.helloworld.HelloWorldConnectionFactory"}} |

what could be wrong? :s
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/807155#807155]

Start a new discussion in IronJacamar at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2098]
daedlus D
2013-04-09 11:45:34 UTC
Permalink
daedlus D [https://community.jboss.org/people/daedlus] created the discussion

"Re: Hello World Example"

To view the discussion, visit: https://community.jboss.org/message/807181#807181

--------------------------------------------------------------
I missed the jboss-deployment-structure.xml in ejb jar deployment that contained the dependency on the deployed rar!
It works after i add this xml file
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/807181#807181]

Start a new discussion in IronJacamar at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2098]
Loading...