Sorry I just read that the other post said to make sure that the JBoss/client directory was on the classpath. I realize that I need it to point to my apps directory so that is can find the classes it is just that I wasn't sure that something was being generated in that directory that I needed in my classpath, but I realize that I just need to have my compiled classes in my classpath.
Thanks for all your help people, Bryan --- Guy Rouillier <[EMAIL PROTECTED]> wrote: > You deploy your EJB to the deploy directory. You > don't deploy your > command-line client anywhere, you just run it, > including in the classpath > the necessary JBoss client jars and the home and > remote interface classes > for your EJB.. > > ----- Original Message ----- > From: "bryan hansen" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Tuesday, July 02, 2002 5:30 PM > Subject: Re: [JBoss-user] Question accessing EJB > from command line. > > > > So should I not be deploying my appliction to the > > default directory then? And instead be deploying > it to > > the client directory? > > > > Bryan > > > > --- Greg Turner <[EMAIL PROTECTED]> > wrote: > > > Here is the properties I use; its slightly > different > > > than yours because > > > mine has 3 properties, not 2: > > > > > > Properties props = new Properties(); > > > props.put > > > > > > ("java.naming.factory.initial","org.jnp.interfaces.NamingContextFactory"); > > > > > > props.put > > > > ("java.naming.provider.url","jnp://localhost:1099"); > > > props.put > > > > > > ("java.naming.factory.url.pkgs","org.jboss.naming:org.jnp.interfaces"); > > > > > > Thats all you need. Get context, ask context > for > > > home, etc. > > > > > > No stubs and skeletons to worry about. JBoss > does > > > away with all that > > > nonsense by using dynamic proxies. Your command > > > line app should be > > > built and run by having the classpath point to > the > > > jars in the > > > jboss_home/client. > > > > > > Greg > > > > > > > > > > > > bryan hansen wrote: > > > > > > > I was unable to find in the documentation how > to > > > > access and ejb from a command line > application. I > > > have > > > > written a simple test class just to test the > > > business > > > > methods on an EJB. I am pretty sure that I > need to > > > get > > > > the stubs and skeltons compiled to talk with > the > > > ejb, > > > > but what is the best way to do this? > > > > > > > > I have an example that trys to access an ejb > from > > > the > > > > command line and I get and AddressHome(my > class) > > > not > > > > found exception. The sample code is: > > > > > > > > <snip> > > > > > > > > env.put(Context.INITIAL_CONTEXT_FACTORY, > > > > "org.jnp.interfaces.NamingContextFactory"); > > > > env.put(Context.PROVIDER_URL, > > > "jnp://localhost:1099"); > > > > > > > > InitialContext iniCtx = new > InitialContext(env); > > > > Object tmp = iniCtx.lookup("ejb/AddressEJB"); > > > > System.out.println("tmp " + tmp); > > > > > > > > </snip> > > > > > > > > Thanks for any help, > > > > > > > > Bryan > > > > > > > > > __________________________________________________ > > > > Do You Yahoo!? > > > > Sign up for SBC Yahoo! Dial - First Month Free > > > > http://sbc.yahoo.com > > > > > > > > > > > > > > ------------------------------------------------------- > > > > This sf.net email is sponsored by:ThinkGeek > > > > Welcome to geek heaven. > > > > http://thinkgeek.com/sf > > > > > _______________________________________________ > > > > JBoss-user mailing list > > > > [EMAIL PROTECTED] > > > > > > > > > > https://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > -- > > > Greg Turner, JBoss Certified Consultant > > > > > > Tiburon Enterprise Systems > > > http://www.tiburon-e-systems.com > > > Box 1171 > > > Tiburon, CA 94920 > > > 415-332-3363 > > > > > > > > > > > > > > > > > > ------------------------------------------------------- > > > Sponsored by: > > > ThinkGeek at http://www.ThinkGeek.com/ > > > _______________________________________________ > > > JBoss-user mailing list > > > [EMAIL PROTECTED] > > > > > > https://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > __________________________________________________ > > Do You Yahoo!? > > Sign up for SBC Yahoo! Dial - First Month Free > > http://sbc.yahoo.com > > > > > > > ------------------------------------------------------- > > Sponsored by: > > ThinkGeek at http://www.ThinkGeek.com/ > > _______________________________________________ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > > https://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > > > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > No, I will not fix your computer. > http://thinkgeek.com/sf > _______________________________________________ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user __________________________________________________ Do You Yahoo!? Sign up for SBC Yahoo! Dial - First Month Free http://sbc.yahoo.com ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek No, I will not fix your computer. http://thinkgeek.com/sf _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user