gdamour     2005/02/20 10:44:48

  Modified:    modules/core/src/java/org/openejb/entity/cmp/pkgenerator
                        AutoIncrementTablePrimaryKeyGeneratorWrapper.java
                        SQLPrimaryKeyGeneratorWrapper.java
                        SequenceTablePrimaryKeyGeneratorWrapper.java
  Log:

  o Add a db-syntax-factory optional element. It corresponds to a database
  syntax factory.
  
  This is used to support discrepencies between various DB and JDBC providers.
  
  For instance, the CONCAT and SUBSTRING functions need to be escaped in the
  case of Derby and not in the case of Oracle.
  
  The default syntax is set to Derby.
  
  o Add a ejb-ql-compiler-factory optional element. It corresponds to the
  strategy used to compile EJB QL queries.
  
  This is used to support discrepencies between the operations supported by
  various DB providers.
  
  For instance, a SELECT OBJECT(A) FROM AASN AS A, IN(A.toB) B may produce
  two SQL queries: one with an INNER JOIN if supported by the DB or a CROSS JOIN
  with the relevant conditions appended to the WHERE clause.
  
  The default compiler strategy is set to Derby.
  
  o PrimaryKeyGenerator.getNextPrimaryKey() throws now a
  DuplicateIdentityException; update accordingly the code.
  
  Revision  Changes    Path
  1.4       +3 -2      
openejb/modules/core/src/java/org/openejb/entity/cmp/pkgenerator/AutoIncrementTablePrimaryKeyGeneratorWrapper.java
  
  Index: AutoIncrementTablePrimaryKeyGeneratorWrapper.java
  ===================================================================
  RCS file: 
/home/projects/openejb/scm/openejb/modules/core/src/java/org/openejb/entity/cmp/pkgenerator/AutoIncrementTablePrimaryKeyGeneratorWrapper.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- AutoIncrementTablePrimaryKeyGeneratorWrapper.java 3 Feb 2005 03:09:53 
-0000       1.3
  +++ AutoIncrementTablePrimaryKeyGeneratorWrapper.java 20 Feb 2005 15:44:48 
-0000      1.4
  @@ -56,6 +56,7 @@
   import org.apache.geronimo.gbean.GBeanInfoBuilder;
   import org.apache.geronimo.gbean.GBeanLifecycle;
   import org.tranql.cache.CacheRow;
  +import org.tranql.cache.DuplicateIdentityException;
   import org.tranql.cache.InTxCache;
   import org.tranql.identity.GlobalIdentity;
   import org.tranql.pkgenerator.AutoIncrementTablePrimaryKeyGenerator;
  @@ -100,7 +101,7 @@
           return delegate.getNextPrimaryKey(cacheRow);
       }
   
  -    public CacheRow updateCache(InTxCache cache, GlobalIdentity id, CacheRow 
cacheRow) throws PrimaryKeyGeneratorException {
  +    public CacheRow updateCache(InTxCache cache, GlobalIdentity id, CacheRow 
cacheRow) throws DuplicateIdentityException {
           return delegate.updateCache(cache, id, cacheRow);
       }
   
  
  
  
  1.7       +3 -2      
openejb/modules/core/src/java/org/openejb/entity/cmp/pkgenerator/SQLPrimaryKeyGeneratorWrapper.java
  
  Index: SQLPrimaryKeyGeneratorWrapper.java
  ===================================================================
  RCS file: 
/home/projects/openejb/scm/openejb/modules/core/src/java/org/openejb/entity/cmp/pkgenerator/SQLPrimaryKeyGeneratorWrapper.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- SQLPrimaryKeyGeneratorWrapper.java        3 Feb 2005 03:09:53 -0000       
1.6
  +++ SQLPrimaryKeyGeneratorWrapper.java        20 Feb 2005 15:44:48 -0000      
1.7
  @@ -60,6 +60,7 @@
   import org.apache.geronimo.gbean.GBeanInfoBuilder;
   import org.apache.geronimo.gbean.GBeanLifecycle;
   import org.tranql.cache.CacheRow;
  +import org.tranql.cache.DuplicateIdentityException;
   import org.tranql.cache.InTxCache;
   import org.tranql.identity.GlobalIdentity;
   import org.tranql.pkgenerator.PrimaryKeyGenerator;
  @@ -122,7 +123,7 @@
           return delegate.getNextPrimaryKey(cacheRow);
       }
   
  -    public CacheRow updateCache(InTxCache cache, GlobalIdentity id, CacheRow 
cacheRow) throws PrimaryKeyGeneratorException {
  +    public CacheRow updateCache(InTxCache cache, GlobalIdentity id, CacheRow 
cacheRow) throws DuplicateIdentityException {
           return delegate.updateCache(cache, id, cacheRow);
       }
   
  
  
  
  1.6       +3 -2      
openejb/modules/core/src/java/org/openejb/entity/cmp/pkgenerator/SequenceTablePrimaryKeyGeneratorWrapper.java
  
  Index: SequenceTablePrimaryKeyGeneratorWrapper.java
  ===================================================================
  RCS file: 
/home/projects/openejb/scm/openejb/modules/core/src/java/org/openejb/entity/cmp/pkgenerator/SequenceTablePrimaryKeyGeneratorWrapper.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- SequenceTablePrimaryKeyGeneratorWrapper.java      3 Feb 2005 03:09:53 
-0000       1.5
  +++ SequenceTablePrimaryKeyGeneratorWrapper.java      20 Feb 2005 15:44:48 
-0000      1.6
  @@ -56,6 +56,7 @@
   import org.apache.geronimo.gbean.GBeanInfoBuilder;
   import org.apache.geronimo.gbean.GBeanLifecycle;
   import org.tranql.cache.CacheRow;
  +import org.tranql.cache.DuplicateIdentityException;
   import org.tranql.cache.InTxCache;
   import org.tranql.identity.GlobalIdentity;
   import org.tranql.pkgenerator.PrimaryKeyGenerator;
  @@ -101,7 +102,7 @@
           return delegate.getNextPrimaryKey(cacheRow);
       }
   
  -    public CacheRow updateCache(InTxCache cache, GlobalIdentity id, CacheRow 
cacheRow) throws PrimaryKeyGeneratorException {
  +    public CacheRow updateCache(InTxCache cache, GlobalIdentity id, CacheRow 
cacheRow) throws DuplicateIdentityException {
           return delegate.updateCache(cache, id, cacheRow);
       }
   
  
  
  

Reply via email to