I'm new to EJB 3.0 and trying out the DI with my ejb's.
I'm using WAS 7.0 as my appserver and I have two EAR's deployed on it. Both have ejb 3 session beans and I need to invoke an ejb in ear 2 from an ejb available in ear 1.
In both my applications, I have a client project which holds the local and remote interfaces, a commons project which contains interfaces which are extended by the remote and local interfaces, then the ejb project and a router project(as the webservice endpoints for the ejb's)
Now to make the remote call, I tried putting the client and commons jar files in the lib directory of EAR, updated the META-INF of the ejb project and tried to use the @EJB annotation, but its giving exceptions, that the EJB's are missing.
I tried to do a JNDI lookup, but it gave NamingException.
Which is the correct way to do a remote bean invoke in ejb 3.0?
Please provide your suggestions.