> > <MLET CODE = "org.jboss.jdbc.DataSourceImpl"
> > ARCHIVE="jboss.jar,classes12.jar" CODEBASE="../lib/ext/">
> >    <ARG TYPE="java.lang.String"
> > VALUE="jdbc:oracle:thin:@evita:1521:orcl">
> >    <ARG TYPE="java.lang.String" VALUE="jdbc/DBMS">  <-- JNDI name here?
> >    <ARG TYPE="java.lang.String" VALUE="oracle.jdbc.driver.OracleDriver">
> >    <ARG TYPE="java.lang.String" VALUE="system">
> >    <ARG TYPE="java.lang.String" VALUE="manager">
> > </MLET>
> >
> >     But starting the server shows this exception:
> >
> > [DataSource] Starting
> > javax.naming.NameNotFoundException: jdbc not bound
> 
> It couldn't handle hierarchical names if subcontexts weren't already
> created (in this case "jdbc" had to be created first).
> 
> Fixed in CVS now.
> 
> /Rickard
> 
> >     Can I make a context.lookup("java:comp/env/jdbc/DBMS") ?
> 
> For the above datasource you can use context.lookup("jdbc/DBMS").
> However, this isn't portable. You should make a ResourceReference in
> your bean descriptor that maps "jdbc/DBMS" in your EJB environment (the
> one you show above) to "jdbc/DBMS" in the global JNDI tree. That way

I am not sure I agree there chief.  

This must be done automatically otherwise we create non-compliance with
the spec (it does say it is the container responsability to provide
this) and more XML madness for our users.  Check out the way it is done
in jBoss 1.0 we check on the type (here your MLET thingy?) and provide
the entry both in java:comp/env and java:comp/env/jdbc.

Somewhere in ContainerMetaData.java 

marc


> your beans are more portable, cause you are allowed to change the name
> "jdbc/DBMS" in the globa� tree without breaking your beans.
> 
> /Rickard
> 
> --
> Rickard �berg
> 
> @home: +46 13 177937
> Email: [EMAIL PROTECTED]
> http://www.telkel.com
> http://www.jboss.org
> http://www.dreambean.com
> 
> --
> --------------------------------------------------------------
> 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