Hi Max,

>
> Any hints on how to use the new and improved J2EE code ?
>

You find a sample session bean using ODMG under
jakarta-ojb\src\ejb\org\apache\ojb\ejb

> Any tips/guide on which classes one should reimplement if the
J2EE-container
> is not JBOSS ?

we use xdoclet to generate the bean interfaces and deployment
descriptor.
Run the "jar_beans" target of the build-xdoclet.xml. This generates a
deployable jar-File (with the sample beans) for jboss.
xdoclet supports many other appServer (see xdoclet docs) you only need
to change the xdoclet target in build-xdoclet.xml.

In ODMGTransactionMonitor_2 we do lookup the TransactionMonitor of
jboss. Here you need the jndi-name of your TM
(jboss: TM_LOOKUP = "java:/TransactionManager")
This could be difficult when using commercial products, because this was
not specified by the EJB spec., hence most vendors hide this jndi name.

We bind a jboss mbean org.jboss.ojb.odmg.ODMGFactory under
"java:ojb/defaultODMG" to get a Implementation instance via jndi.
For a first step its also possible using OJBJ2EE_2 directly in your
bean.

It's recommend first using the OJB default DB (hsql).
When using datasources from your appServer change your OJB.properties
file:
useAutoCommit=0
ConnectionFactoryClass=org.apache.ojb.broker.accesslayer.ConnectionFacto
ryPassThroughImpl

that's it! ;-)

regards,
Armin

>
> Thanx! :)
>
> /max
>
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>
>
>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to