Adjusted Fix for Issue 56 - Using findIterate with MySQL streams the

entire result set at once.  This makes the fix specific to the
DatabasePlatform and findIterate() or findVisit().
This commit is contained in:
Rob Bygrave
2013-11-07 23:58:15 +13:00
parent b896e55af1
commit 9d8fe97de0
4 changed files with 35 additions and 6 deletions
@@ -25,6 +25,8 @@ public class CQueryEngine {
private static final Logger logger = LoggerFactory.getLogger(CQueryEngine.class);
private final DatabasePlatform dbPlatform;
private final CQueryBuilder queryBuilder;
private final BackgroundExecutor backgroundExecutor;
@@ -33,6 +35,7 @@ public class CQueryEngine {
public CQueryEngine(DatabasePlatform dbPlatform, Binder binder, BackgroundExecutor backgroundExecutor) {
this.dbPlatform = dbPlatform;
this.backgroundExecutor = backgroundExecutor;
this.queryBuilder = new CQueryBuilder(backgroundExecutor, dbPlatform, binder);
}
@@ -122,7 +125,7 @@ public class CQueryEngine {
try {
if (!cquery.prepareBindExecuteQueryForwardOnly()) {
if (!cquery.prepareBindExecuteQueryForwardOnly(dbPlatform.isForwardOnlyHintOnFindIterate())) {
// query has been cancelled already
logger.trace("Future fetch already cancelled");
return null;