Re: Retrieving EJB (v3) via JNDI
Florent BENOIT <[email protected]> Mon, 20 Jun 2011 08:02:34 +0200
| Newsgroups | gmane.comp.java.objectweb.jonas |
|---|---|
| Message-ID | <[email protected]> |
Hi, I think that if you've this kind of error, it's because all the required classes to build an EJB3 proxy haven't been found (so you only have the reference object stored in JNDI when you're performing the lookup) Check for example that JONAS_ROOT/lib/client.jar is in your client classpath or try to use SmartFactory on the client side (it downloads the required classes from the server) Regards, Florent On 06/17/2011 06:17 PM, [email protected] wrote: > Dear, > > > I try to retrieve stateless EJB (v3) via JNDI. > > The lookup works partially: > - I get a javax.naming.Reference object that can't be casted into IImporter. > > (The EJB is defined via: > @Stateless(name = "ImporterBean", mappedName = "ImporterBean") > @Remote(IImporter.class) > public class ImporterBean implements IImporter { ... > ) > > I use ImporterBean as EJB JNDI name for the lookup. > > I don't understand the mistake, it is may be due to the EJB JNDI name used ? > > Can you help me ? > > > Kind regards, > > Antonin. > > ******************************************************************************** > IMPORTANT.Les informations contenues dans ce message electronique y compris les fichiers attaches sont strictement confidentielles > et peuvent etre protegees par la loi. > Ce message electronique est destine exclusivement au(x) destinataire(s) mentionne(s) ci-dessus. > Si vous avez recu ce message par erreur ou s il ne vous est pas destine, veuillez immediatement le signaler a l expediteur et effacer ce message > et tous les fichiers eventuellement attaches. > Toute lecture, exploitation ou transmission des informations contenues dans ce message est interdite. > Tout message electronique est susceptible d alteration. > A ce titre, le Groupe France Telecom decline toute responsabilite notamment s il a ete altere, deforme ou falsifie. > De meme, il appartient au destinataire de s assurer de l absence de tout virus. > > IMPORTANT.This e-mail message and any attachments are strictly confidential and may be protected by law. This message is > intended only for the named recipient(s) above. > If you have received this message in error, or are not the named recipient(s), please immediately notify the sender and delete this e-mail message. > Any unauthorized view, usage or disclosure ofthis message is prohibited. > Since e-mail messages may not be reliable, France Telecom Group shall not be liable for any message if modified, changed or falsified. > Additionally the recipient should ensure they are actually virus free. > ******************************************************************************** > >