User: olegnitz Date: 01/10/22 18:32:55 Modified: src/main/org/jboss/ejb/plugins/cmp/jdbc JDBCStoreManager.java Log: Fix by Dave Smith: a bug in read ahead stuff, failed reading were reported as successfull. Revision Changes Path 1.11 +6 -5 jboss/src/main/org/jboss/ejb/plugins/cmp/jdbc/JDBCStoreManager.java Index: JDBCStoreManager.java =================================================================== RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/ejb/plugins/cmp/jdbc/JDBCStoreManager.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- JDBCStoreManager.java 2001/10/09 00:29:43 1.10 +++ JDBCStoreManager.java 2001/10/23 01:32:55 1.11 @@ -54,7 +54,7 @@ * * @author <a href="mailto:[EMAIL PROTECTED]">Dain Sundstrom</a> * @see org.jboss.ejb.EntityPersistenceStore - * @version $Revision: 1.10 $ + * @version $Revision: 1.11 $ */ public class JDBCStoreManager extends CMPStoreManager { /** @@ -214,7 +214,6 @@ } } if (!done) { -System.out.println("loadField"); loadFieldCommand.execute(fieldsToLoad, ctx); } } @@ -264,14 +263,15 @@ results = (FinderResults) readAheadCache.get(new Long(key.getListId())); if (results != null) { try { -System.out.println("readAhead"); readAheadCommand.execute(fieldsToLoad, results, key.getIndex(), Math.min(results.size(), key.getIndex() + readAheadLimit)); fieldsToLoad = fillFromPreloaded(fields, ctx); - if (fieldsToLoad != null) { + if (fieldsToLoad == null) { + success = true; + } else { log.warn("Didn't read ahead field '" + fieldsToLoad[0].getMetaData().getFieldName() + "'"); + success = false; } - success = true; } catch (RemoteException ex) { log.warn("Read ahead failed", ex); } @@ -419,6 +419,7 @@ preloadKey = new PreloadKey(trans, entityKey, field.getMetaData().getFieldName()); fieldValue = preloadedData.remove(preloadKey); + log.debug("Getting Preload " + preloadKey + " " + field.getMetaData().getFieldName() + " " + fieldValue); found = (fieldValue != null); if (fieldValue == NULL_VALUE) { // due to this trick we avoid synchronization on preloadedData fieldValue = null;
_______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development