Joel Shellman wrote:
> 
> First of all. I successfully got a HelloWorld bean deployed and running.
> And it didn't take long either.
> 
> Since these are newbie questions, I'll group them together.
> 
> 1) I noticed that if you drop a jar in the beans directory, it
> automatically tries to deploy it (within seconds, too, cool!). How is
> this done? Is it polling on that directory to check for new files? Is
> that meant to be a development convenience and not used in production
> (because polling like that would be a waste of CPU in production
> environment)? Is there a way to turn it off?
>  ejb.jar,

it is meant as a production convenience... you will make the cycle of
test configurable, turn off as well.

I would not overestimate the importance of the CPU pooling


> 2) Can someone kindly explain to me why things don't work when you put
> the various jars (ejb.jar, ejboss-1.0DR1-jdk1.2.2.jar, etc.) in the
> jre/lib/ext directory? I've noticed that with another software I tested
> recently. Is there just a bug with the way the JDK handles 

it needs the directory layout, the jar only won't work. 


> 3) Noticed that setSessionContext() is getting called twice for every
> time I call in. Here's the output and source:
> 
> JoelTestBean.setSessionContext() called
> JoelTestBean.setSessionContext() called
> Received helloWorld() call
> JoelTestBean.setSessionContext() called
> JoelTestBean.setSessionContext() called
> Received helloWorld() call
> JoelTestBean.setSessionContext() called
> JoelTestBean.setSessionContext() called
> Received helloWorld() call
> JoelTestBean.setSessionContext() called
> JoelTestBean.setSessionContext() called
> Received helloWorld() call
> 
> Bean source:
> public class JoelTestBean implements SessionBean {
> 
>   private SessionContext sessionContext;
> 
>   public void ejbCreate() throws RemoteException, CreateException {
>     System.out.println("JoelTestBean.ejbCreate() called");
>   }
> 
>   public void ejbActivate() throws RemoteException {
>     System.out.println("JoelTestBean.ejbActivate() called");
>   }
> 
>   public void ejbPassivate() throws RemoteException {
>     System.out.println("JoelTestBean.ejbPassivate() called");
>   }
> 
>   public void ejbRemove() throws RemoteException {
>     System.out.println("JoelTestBean.ejbRemove() called");
>   }
> 
>   public void setSessionContext(SessionContext context) throws
> RemoteException {
>     System.out.println("JoelTestBean.setSessionContext() called");
>     sessionContext = context;
>   }
> 
>   public String helloWorld() throws RemoteException {
>     System.out.println("Received helloWorld() call");
>     return "Hello World.";
>   }
> }
> 
> Client source:
> package test;
> 
> import javax.naming.Context;
> import javax.naming.InitialContext;
> 
> import java.util.Properties;
> 
> public class JoelTestClient {
> 
>   public JoelTestClient() {
>   }
> 
>   public void test() {
>     try {
>       Properties prop = new Properties();
>       prop.put(Context.INITIAL_CONTEXT_FACTORY,
> "org.jnp.naming.interfaces.NamingContextFactory");
>       prop.put(Context.URL_PKG_PREFIXES, "org.jnp.naming.interfaces");
>       prop.put(Context.PROVIDER_URL, "127.0.0.1");
>       Context ctx = new InitialContext(prop);
>       System.out.println("Setup initial context.");
>       JoelTestHome home = (JoelTestHome)ctx.lookup("JoelTest");
>       if (home != null ) {
>         System.out.println("Got Home.");
>       }
>       JoelTest testBean = home.create();
>       String testResponse = testBean.helloWorld();
>       System.out.println("Received: [" + testResponse + "] in response
> to helloWorld() call.");
>     }
>     catch (Exception e) {
>       e.printStackTrace();
>     }
>   }
> 
>   public static void main(String[] args) {
> 
>     JoelTestClient client = new JoelTestClient();
> 
>     client.test();
>   }
> }

...

do you declare your bean as stateless?

I need the xml file as well.  better send a jar privately



> 
> 4) A long time ago I tried out ejboss and it had a GUI. Was that GUI
> removed? Replaced by the auto deployment method in use now (drop them in
> the beans dir)?

yes,

but the gui is coming back.  Juha is working on a start stop interface.

> 5) Any estimate on how close version 1 is? Or at least how soon there
> will be binaries available again (which I imagine is the same question
> it seems)?

I am working on DR2.  DR2 should rapidly evolve (1-2 weeks) to PR1. 
Public Release 1 will feature binaries available.  DR or Developers
Releases are only available from CVS (most people are then dev oriented)

> 

> Thanks!

no problem

marc
> --
> Joel Shellman
> Ants.com: the world's fastest growing freelance marketplace
> http://www.ants.com/90589781
> 
> --
> --------------------------------------------------------------
> To subscribe:        [EMAIL PROTECTED]
> To unsubscribe:      [EMAIL PROTECTED]
> Problems?:           [EMAIL PROTECTED]


--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to