You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by asheesh <as...@q2aindia.com> on 2001/05/15 12:14:57 UTC

Re: any EJB calling example available?

hi,

I am not sure if there is some recommended way or not , but it depends on u
to decide about the calling mechanism and consider other performance issues
according to EJB specifications and J2EE architecture.

cheers
asheesh

----- Original Message -----
From: May <ma...@hotmail.com>
To: <to...@jakarta.apache.org>
Sent: Monday, September 03, 2001 5:36 PM
Subject: Re: any EJB calling example available?


>
> Thank you Asheesh.
> So my question is where is the right place to
> do the lookup and stuff when using struts.
>
> At the moment, I'm doing them in the Action class,
> Is there a recommended way calling EJB from struts?
>
> Thanks you.
> May
>
> ----- Original Message -----
> From: "asheesh" <as...@q2aindia.com>
> To: <to...@jakarta.apache.org>
> Sent: Thursday, August 30, 2001 1:02 PM
> Subject: Re: any EJB calling example available?
>
>
> > hi,
> >
> >     i think this will help
> >
> >     Context ctx= new InitialContext();
> >      Object obj= ctx.lookup("JNDIName-OF ur Bean");
> >      beanHome = (BeanHome)
> PortableRemoteObject.narrow(obj,BeanHome.class);
> >      beanRemote = beanHome.create();
> >
> > pls consider that BeanHome.class & BeanRemote should be in ur servlet
> > classpath
> >
> > regards
> > asheesh
> >
> >
> > ----- Original Message -----
> > From: May <ma...@hotmail.com>
> > To: <to...@jakarta.apache.org>
> > Sent: Thursday, August 30, 2001 8:36 AM
> > Subject: any EJB calling example available?
> >
> >
> > > Hello !
> > > Is there any struts calling EJB examples available ?
> > > Or any relating documents.
> > > I would greatly appreciate if you could let me know.
> > >
> > > Thanks in advance.
> > > May
> >
> >