db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject cvs commit: jakarta-ojb/xdocs deployment.xml
Date Mon, 13 Jan 2003 17:49:19 GMT
arminw      2003/01/13 09:49:19

  Modified:    xdocs    deployment.xml
  Log:
  update doc
  
  Revision  Changes    Path
  1.8       +40 -5     jakarta-ojb/xdocs/deployment.xml
  
  Index: deployment.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ojb/xdocs/deployment.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- deployment.xml	23 Dec 2002 10:08:10 -0000	1.7
  +++ deployment.xml	13 Jan 2003 17:49:19 -0000	1.8
  @@ -262,15 +262,49 @@
   <source><![CDATA[
   ConnectionFactoryClass=
   org.apache.ojb.broker.accesslayer.ConnectionFactoryManagedImpl
  -useAutoCommit=0
  +
   OJBTxManagerClass=org.apache.ojb.odmg.JTATxManager
  +
   JTATransactionManagerClass=
   org.apache.ojb.otm.transaction.factory.JBossTransactionManagerFactory
   ]]></source>
   </p>
   
   <p>
  -<b>3a. Inside your EJB's you can get a handle on the ODMG like this:</b>
  +<b>3. Declare datasources in the repository (repository_database) file:</b>
  +Do only use datasources from the appServer to connect your databases.
  +<source><![CDATA[
  +<!-- Datasource example -->
  +<jdbc-connection-descriptor
  +    jcd-alias="default"
  +    default-connection="true"
  +    platform="Hsqldb"
  +    jdbc-level="2.0"
  +    jndi-datasource-name="java:DefaultDS"
  +    username="sa"
  +    password=""
  +    eager-release="true"
  +    batch-mode="false"
  +    useAutoCommit="0"
  +    ignoreAutoCommitExceptions="false"
  +>
  +
  +    <sequence-manager className=
  +    "org.apache.ojb.broker.util.sequence.SequenceManagerNextValImpl">
  +    </sequence-manager>
  +</jdbc-connection-descriptor>
  +]]></source>
  +The attribute <code>useAutoCommit="0"</code> is mandatory
  +in managed environments, because it's in most cases not
  +allowed to change autoCommit state.
  +<br/>
  +When using jboss >3.0 you have to set
  +<code>eager-release="true"</code> - when using other appServer
  +<code>false</code> should be ok.
  +</p>
  +
  +<p>
  +<b>4a. Inside your EJB's you can get a handle on the ODMG like this:</b>
   <source><![CDATA[
   ODMGFactory factory =
   (ODMGFactory) context.lookup("java:/ojb/defaultODMG");
  @@ -279,7 +313,7 @@
   </p>
   
   <p>
  -<b>3b. Inside your EJB's you can get a handle on the PB like this:</b>
  +<b>4b. Inside your EJB's you can get a handle on the PB like this:</b>
   <source><![CDATA[
   context = new InitialContext();
   pbf = ((PBFactoryIF) context.lookup(
  @@ -320,8 +354,9 @@
   <p>
   After running the ant target you will find a <code>jakarta-ojb-XXX-beans.jar</code>
   and a <code>jakarta-ojb-XXX-client.jar</code> in the [jakarta-ojb]/dist directory.
  -Put the bean jar in JBoss /deploy dir and the OJB application jar in /lib. This
  -solution is not re-deployable. If someone find a solution that makes the sample
  +Put the bean jar in JBoss /deploy dir and the OJB application jar in /lib, also
  +add the OJB configuration files (OJB.properties + repositoryXXX.xml) to
  +classpath. This solution is not re-deployable. If someone find a solution that makes the
sample
   beans re-deployable in jboss, please let me know.
   </p>
   </subsection>
  
  
  

Mime
View raw message