db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b..@apache.org
Subject cvs commit: db-ojb/src/java/org/apache/ojb/broker/singlevm PersistenceBrokerImpl.java
Date Wed, 02 Apr 2003 19:49:46 GMT
brj         2003/04/02 11:49:46

  Modified:    src/java/org/apache/ojb/broker/singlevm
                        PersistenceBrokerImpl.java
  Log:
  improved logging in getRsIteratorFromQuery()
  
  Revision  Changes    Path
  1.150     +7 -3      db-ojb/src/java/org/apache/ojb/broker/singlevm/PersistenceBrokerImpl.java
  
  Index: PersistenceBrokerImpl.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/singlevm/PersistenceBrokerImpl.java,v
  retrieving revision 1.149
  retrieving revision 1.150
  diff -u -r1.149 -r1.150
  --- PersistenceBrokerImpl.java	28 Mar 2003 16:30:13 -0000	1.149
  +++ PersistenceBrokerImpl.java	2 Apr 2003 19:49:45 -0000	1.150
  @@ -2217,6 +2217,7 @@
       {
           if (query instanceof QueryBySQL)
           {
  +            logger.debug("Creating SQL-RsIterator for class ["+cld.getClassNameOfObject()+"]");
               String sql = ((QueryBySQL) query).getSql();
               return factory.createRsIterator(sql, cld, this);
           }
  @@ -2224,12 +2225,13 @@
           if (!cld.isExtent())
           {
               // no extents just use the plain vanilla RsIterator
  +            logger.debug("Creating RsIterator for class ["+cld.getClassNameOfObject()+"]");
               return factory.createRsIterator(query, cld, this);
           }
   
           OJBIterator iter = null;
           String lastUsedTable = cld.getFullTableName();
  -        logger.debug("Creating one RsIterator per extent class of ["+cld.getClassNameOfObject()+"]");
  +        logger.debug("Creating ChainingIterator for class ["+cld.getClassNameOfObject()+"]");
           iter = new ChainingIterator();
           Vector extentClasses = cld.getExtentClasses();
           Class ec = null;
  @@ -2237,6 +2239,7 @@
           // BRJ: add base class iterator
           if (!cld.isInterface())
           {
  +            logger.debug("Adding RsIterator for class ["+cld.getClassNameOfObject()+"]
to ChainingIterator");
               ((ChainingIterator) iter).addIterator(factory.createRsIterator(query, cld,
this));
           }
   
  @@ -2248,13 +2251,14 @@
               // read same table only once
               if (!cld.isInterface() && cld.getFullTableName().equals(lastUsedTable))
               {
  +                logger.debug("Skipping class ["+cld.getClassNameOfObject()+"]");
                   continue;
               }
               lastUsedTable = cld.getFullTableName();
   
               // add the iterator to the chaining iterator.
               // BRJ: look for multilevel hierarchies
  -            logger.debug("Adding RsIterator of class ["+ec+"] to ChainingRsIterator");
  +            logger.debug("Adding RsIterator of class ["+ec+"] to ChainingIterator");
               ((ChainingIterator) iter).addIterator(getRsIteratorFromQuery(query, cld, factory));
           }
           return iter;
  
  
  

Mime
View raw message