mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-18 14:58:47 +00:00
Add MetaInfoManager API, remove MetaQueryStatistic entity bean, refactor query execution stats collection
This commit is contained in:
1 parent
05dcdf162b
commit
6bd8c2bd05
40 files changed
+1375
-1093
No files matched your search
@@ -6,6 +6,7 @@ import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
import javax.persistence.PersistenceException;
|
||||
|
||||
@@ -39,6 +40,7 @@ import com.avaje.ebeaninternal.server.querydefn.OrmQueryProperties;
|
||||
import com.avaje.ebeaninternal.server.transaction.DefaultPersistenceContext;
|
||||
import com.avaje.ebeaninternal.server.type.DataBind;
|
||||
import com.avaje.ebeaninternal.server.type.DataReader;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
@@ -204,8 +206,6 @@ public class CQuery<T> implements DbReadContext, CancelableQuery {
|
||||
|
||||
private final CQueryPlan queryPlan;
|
||||
|
||||
private long startNano;
|
||||
|
||||
private final Mode queryMode;
|
||||
|
||||
private final boolean autoFetchProfiling;
|
||||
@@ -213,14 +213,17 @@ public class CQuery<T> implements DbReadContext, CancelableQuery {
|
||||
private final ObjectGraphNode autoFetchParentNode;
|
||||
|
||||
private final AutoFetchManager autoFetchManager;
|
||||
|
||||
private final WeakReference<NodeUsageListener> autoFetchManagerRef;
|
||||
|
||||
private int executionTimeMicros;
|
||||
|
||||
private final Boolean readOnly;
|
||||
|
||||
private final SpiExpressionList<?> filterMany;
|
||||
|
||||
private long startNano;
|
||||
|
||||
private long executionTimeMicros;
|
||||
|
||||
/**
|
||||
* Create the Sql select based on the request.
|
||||
*/
|
||||
@@ -520,7 +523,7 @@ public class CQuery<T> implements DbReadContext, CancelableQuery {
|
||||
}
|
||||
}
|
||||
|
||||
public int getQueryExecutionTimeMicros() {
|
||||
public long getQueryExecutionTimeMicros() {
|
||||
return executionTimeMicros;
|
||||
}
|
||||
|
||||
@@ -638,7 +641,7 @@ public class CQuery<T> implements DbReadContext, CancelableQuery {
|
||||
protected void updateExecutionStatistics() {
|
||||
try {
|
||||
long exeNano = System.nanoTime() - startNano;
|
||||
executionTimeMicros = (int) exeNano / 1000;
|
||||
executionTimeMicros = TimeUnit.NANOSECONDS.toMicros(exeNano);
|
||||
|
||||
if (autoFetchProfiling) {
|
||||
autoFetchManager
|
||||
@@ -674,7 +677,7 @@ public class CQuery<T> implements DbReadContext, CancelableQuery {
|
||||
}
|
||||
|
||||
protected boolean hasNextBean(boolean inForeground) throws SQLException {
|
||||
|
||||
|
||||
if (!readBeanInternal(inForeground)) {
|
||||
return false;
|
||||
|
||||
|
||||
@@ -115,7 +115,7 @@ public class CQueryBuilder implements Constants {
|
||||
String sql = s.getSql();
|
||||
|
||||
// cache the query plan
|
||||
queryPlan = new CQueryPlan(sql, sqlTree, false, s.isIncludesRowNumberColumn(), predicates.getLogWhereSql());
|
||||
queryPlan = new CQueryPlan(query.getBeanType(), sql, sqlTree, false, s.isIncludesRowNumberColumn(), predicates.getLogWhereSql());
|
||||
|
||||
request.putQueryPlan(queryPlan);
|
||||
return new CQueryFetchIds(request, predicates, sql, backgroundExecutor);
|
||||
@@ -171,7 +171,7 @@ public class CQueryBuilder implements Constants {
|
||||
}
|
||||
|
||||
// cache the query plan
|
||||
queryPlan = new CQueryPlan(sql, sqlTree, false, s.isIncludesRowNumberColumn(), predicates.getLogWhereSql());
|
||||
queryPlan = new CQueryPlan(query.getBeanType(), sql, sqlTree, false, s.isIncludesRowNumberColumn(), predicates.getLogWhereSql());
|
||||
request.putQueryPlan(queryPlan);
|
||||
|
||||
return new CQueryRowCount(request, predicates, sql);
|
||||
|
||||
@@ -9,38 +9,37 @@ import com.avaje.ebeaninternal.server.core.OrmQueryRequest;
|
||||
|
||||
/**
|
||||
* QueryIterator that does not require a buffer for secondary queries.
|
||||
*
|
||||
* @author rbygrave
|
||||
*/
|
||||
class CQueryIteratorSimple<T> implements QueryIterator<T> {
|
||||
|
||||
private final CQuery<T> cquery;
|
||||
private final OrmQueryRequest<T> request;
|
||||
private final CQuery<T> cquery;
|
||||
private final OrmQueryRequest<T> request;
|
||||
|
||||
CQueryIteratorSimple(CQuery<T> cquery, OrmQueryRequest<T> request){
|
||||
this.cquery = cquery;
|
||||
this.request = request;
|
||||
}
|
||||
|
||||
public boolean hasNext() {
|
||||
try {
|
||||
return cquery.hasNextBean(true);
|
||||
} catch (SQLException e){
|
||||
throw cquery.createPersistenceException(e);
|
||||
}
|
||||
}
|
||||
CQueryIteratorSimple(CQuery<T> cquery, OrmQueryRequest<T> request) {
|
||||
this.cquery = cquery;
|
||||
this.request = request;
|
||||
}
|
||||
|
||||
public T next() {
|
||||
return cquery.getLoadedBean();
|
||||
public boolean hasNext() {
|
||||
try {
|
||||
request.flushPersistenceContextOnIterate();
|
||||
return cquery.hasNextBean(true);
|
||||
} catch (SQLException e) {
|
||||
throw cquery.createPersistenceException(e);
|
||||
}
|
||||
}
|
||||
|
||||
public void close() {
|
||||
cquery.updateExecutionStatistics();
|
||||
cquery.close();
|
||||
request.endTransIfRequired();
|
||||
}
|
||||
public T next() {
|
||||
return cquery.getLoadedBean();
|
||||
}
|
||||
|
||||
public void remove() {
|
||||
throw new PersistenceException("Remove not allowed");
|
||||
}
|
||||
public void close() {
|
||||
cquery.updateExecutionStatistics();
|
||||
cquery.close();
|
||||
request.endTransIfRequired();
|
||||
}
|
||||
|
||||
public void remove() {
|
||||
throw new PersistenceException("Remove not allowed");
|
||||
}
|
||||
}
|
||||
@@ -10,58 +10,58 @@ import com.avaje.ebeaninternal.server.core.OrmQueryRequest;
|
||||
|
||||
/**
|
||||
* A QueryIterator that uses a buffer to execute secondary queries periodically.
|
||||
*
|
||||
* @author rbygrave
|
||||
*/
|
||||
class CQueryIteratorWithBuffer<T> implements QueryIterator<T> {
|
||||
|
||||
private final CQuery<T> cquery;
|
||||
private final int bufferSize;
|
||||
private final OrmQueryRequest<T> request;
|
||||
private final ArrayList<T> buffer;
|
||||
private final CQuery<T> cquery;
|
||||
private final int bufferSize;
|
||||
private final OrmQueryRequest<T> request;
|
||||
private final ArrayList<T> buffer;
|
||||
|
||||
private boolean moreToLoad = true;
|
||||
private boolean moreToLoad = true;
|
||||
|
||||
CQueryIteratorWithBuffer(CQuery<T> cquery, OrmQueryRequest<T> request, int bufferSize) {
|
||||
this.cquery = cquery;
|
||||
this.request = request;
|
||||
this.bufferSize = bufferSize;
|
||||
this.buffer = new ArrayList<T>(bufferSize);
|
||||
}
|
||||
CQueryIteratorWithBuffer(CQuery<T> cquery, OrmQueryRequest<T> request, int bufferSize) {
|
||||
this.cquery = cquery;
|
||||
this.request = request;
|
||||
this.bufferSize = bufferSize;
|
||||
this.buffer = new ArrayList<T>(bufferSize);
|
||||
}
|
||||
|
||||
public boolean hasNext() {
|
||||
try {
|
||||
if (buffer.isEmpty() && moreToLoad) {
|
||||
// load buffer
|
||||
int i = -1;
|
||||
while (moreToLoad && ++i < bufferSize) {
|
||||
if (cquery.hasNextBean(true)) {
|
||||
buffer.add(cquery.getLoadedBean());
|
||||
} else {
|
||||
moreToLoad = false;
|
||||
}
|
||||
}
|
||||
// execute secondary queries
|
||||
request.executeSecondaryQueries(bufferSize);
|
||||
}
|
||||
return !buffer.isEmpty();
|
||||
public boolean hasNext() {
|
||||
try {
|
||||
if (buffer.isEmpty() && moreToLoad) {
|
||||
// load buffer
|
||||
request.flushPersistenceContextOnIterate();
|
||||
|
||||
} catch (SQLException e) {
|
||||
throw cquery.createPersistenceException(e);
|
||||
int i = -1;
|
||||
while (moreToLoad && ++i < bufferSize) {
|
||||
if (cquery.hasNextBean(true)) {
|
||||
buffer.add(cquery.getLoadedBean());
|
||||
} else {
|
||||
moreToLoad = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
// execute secondary queries
|
||||
request.executeSecondaryQueries(bufferSize);
|
||||
}
|
||||
return !buffer.isEmpty();
|
||||
|
||||
public T next() {
|
||||
return buffer.remove(0);
|
||||
} catch (SQLException e) {
|
||||
throw cquery.createPersistenceException(e);
|
||||
}
|
||||
}
|
||||
|
||||
public void close() {
|
||||
cquery.updateExecutionStatistics();
|
||||
cquery.close();
|
||||
request.endTransIfRequired();
|
||||
}
|
||||
public T next() {
|
||||
return buffer.remove(0);
|
||||
}
|
||||
|
||||
public void remove() {
|
||||
throw new PersistenceException("Remove not allowed");
|
||||
}
|
||||
public void close() {
|
||||
cquery.updateExecutionStatistics();
|
||||
cquery.close();
|
||||
request.endTransIfRequired();
|
||||
}
|
||||
|
||||
public void remove() {
|
||||
throw new PersistenceException("Remove not allowed");
|
||||
}
|
||||
}
|
||||
@@ -4,9 +4,9 @@ import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
|
||||
import com.avaje.ebean.config.dbplatform.SqlLimitResponse;
|
||||
import com.avaje.ebean.meta.MetaQueryStatistic;
|
||||
import com.avaje.ebeaninternal.server.core.OrmQueryRequest;
|
||||
import com.avaje.ebeaninternal.server.deploy.BeanProperty;
|
||||
import com.avaje.ebeaninternal.server.query.CQueryPlanStats.Snapshot;
|
||||
import com.avaje.ebeaninternal.server.type.DataBind;
|
||||
import com.avaje.ebeaninternal.server.type.DataReader;
|
||||
import com.avaje.ebeaninternal.server.type.RsetDataReader;
|
||||
@@ -51,7 +51,9 @@ public class CQueryPlan {
|
||||
*/
|
||||
private final BeanProperty[] encryptedProps;
|
||||
|
||||
private CQueryStats queryStats = new CQueryStats();
|
||||
private final CQueryPlanStats stats;
|
||||
|
||||
private final Class<?> beanType;
|
||||
|
||||
/**
|
||||
* Create a query plan based on a OrmQueryRequest.
|
||||
@@ -59,6 +61,8 @@ public class CQueryPlan {
|
||||
public CQueryPlan(OrmQueryRequest<?> request, SqlLimitResponse sqlRes, SqlTree sqlTree,
|
||||
boolean rawSql, String logWhereSql, String luceneQueryDescription) {
|
||||
|
||||
this.beanType = request.getBeanDescriptor().getBeanType();
|
||||
this.stats = new CQueryPlanStats(this);
|
||||
this.hash = request.getQueryPlanHash();
|
||||
this.autofetchTuned = request.getQuery().isAutofetchTuned();
|
||||
if (sqlRes != null){
|
||||
@@ -77,9 +81,11 @@ public class CQueryPlan {
|
||||
/**
|
||||
* Create a query plan for a raw sql query.
|
||||
*/
|
||||
public CQueryPlan(String sql, SqlTree sqlTree,
|
||||
public CQueryPlan(Class<?> beanType, String sql, SqlTree sqlTree,
|
||||
boolean rawSql, boolean rowNumberIncluded, String logWhereSql) {
|
||||
|
||||
this.beanType = beanType;
|
||||
this.stats = new CQueryPlanStats(this);
|
||||
this.hash = 0;
|
||||
this.autofetchTuned = false;
|
||||
this.sql = sql;
|
||||
@@ -90,23 +96,27 @@ public class CQueryPlan {
|
||||
this.encryptedProps = sqlTree.getEncryptedProps();
|
||||
}
|
||||
|
||||
public boolean isLucene() {
|
||||
return false;
|
||||
public String toString() {
|
||||
return beanType+" hash:"+hash;
|
||||
}
|
||||
|
||||
public DataReader createDataReader(ResultSet rset){
|
||||
|
||||
return new RsetDataReader(rset);
|
||||
}
|
||||
public Class<?> getBeanType() {
|
||||
return beanType;
|
||||
}
|
||||
|
||||
public void bindEncryptedProperties(DataBind dataBind) throws SQLException {
|
||||
if (encryptedProps != null){
|
||||
for (int i = 0; i < encryptedProps.length; i++) {
|
||||
String key = encryptedProps[i].getEncryptKey().getStringValue();
|
||||
dataBind.setString(key);
|
||||
}
|
||||
}
|
||||
}
|
||||
public DataReader createDataReader(ResultSet rset) {
|
||||
|
||||
return new RsetDataReader(rset);
|
||||
}
|
||||
|
||||
public void bindEncryptedProperties(DataBind dataBind) throws SQLException {
|
||||
if (encryptedProps != null) {
|
||||
for (int i = 0; i < encryptedProps.length; i++) {
|
||||
String key = encryptedProps[i].getEncryptKey().getStringValue();
|
||||
dataBind.setString(key);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isAutofetchTuned() {
|
||||
return autofetchTuned;
|
||||
@@ -140,33 +150,33 @@ public class CQueryPlan {
|
||||
* Reset the query statistics.
|
||||
*/
|
||||
public void resetStatistics() {
|
||||
queryStats = new CQueryStats();
|
||||
stats.reset();
|
||||
}
|
||||
|
||||
/**
|
||||
* Register an execution time against this query plan;
|
||||
*/
|
||||
public void executionTime(int loadedBeanCount, int timeMicros) {
|
||||
// Atomic operation
|
||||
queryStats = queryStats.add(loadedBeanCount, timeMicros);
|
||||
public void executionTime(long loadedBeanCount, long timeMicros) {
|
||||
|
||||
stats.add(loadedBeanCount, timeMicros);
|
||||
}
|
||||
|
||||
public Snapshot getSnapshot(boolean reset) {
|
||||
return stats.getSnapshot(reset);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the current query statistics.
|
||||
*/
|
||||
public CQueryStats getQueryStats() {
|
||||
return queryStats;
|
||||
public CQueryPlanStats getQueryStats() {
|
||||
return stats;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the time this query plan was last used.
|
||||
*/
|
||||
public long getLastQueryTime(){
|
||||
return queryStats.getLastQueryTime();
|
||||
return stats.getLastQueryTime();
|
||||
}
|
||||
|
||||
public MetaQueryStatistic createMetaQueryStatistic(String beanName) {
|
||||
return queryStats.createMetaQueryStatistic(beanName, this);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,154 @@
|
||||
|
||||
package com.avaje.ebeaninternal.server.query;
|
||||
|
||||
import java.util.concurrent.atomic.AtomicLong;
|
||||
|
||||
import com.avaje.ebean.meta.MetaBeanQueryPlanStatistic;
|
||||
import com.avaje.ebeaninternal.server.util.LongAdder;
|
||||
|
||||
/**
|
||||
* Statistics for a specific query plan that can accumulate.
|
||||
*/
|
||||
public final class CQueryPlanStats {
|
||||
|
||||
private final CQueryPlan queryPlan;
|
||||
|
||||
private final LongAdder count = new LongAdder();
|
||||
|
||||
private final LongAdder totalTime = new LongAdder();
|
||||
|
||||
private final LongAdder totalBeans = new LongAdder();
|
||||
|
||||
private final AtomicLong maxTime = new AtomicLong();
|
||||
|
||||
private final AtomicLong startTime = new AtomicLong(System.currentTimeMillis());
|
||||
|
||||
private long lastQueryTime;
|
||||
|
||||
|
||||
public CQueryPlanStats(CQueryPlan queryPlan) {
|
||||
this.queryPlan = queryPlan;
|
||||
}
|
||||
|
||||
public void add(long loadedBeanCount, long timeMicros) {
|
||||
count.increment();
|
||||
totalBeans.add(loadedBeanCount);
|
||||
totalTime.add(timeMicros);
|
||||
if (timeMicros > maxTime.get()) {
|
||||
// effectively a high water mark
|
||||
maxTime.set(timeMicros);
|
||||
}
|
||||
lastQueryTime = System.currentTimeMillis();
|
||||
}
|
||||
|
||||
public void reset() {
|
||||
count.reset();
|
||||
totalBeans.reset();
|
||||
totalTime.reset();
|
||||
maxTime.set(0);
|
||||
startTime.set(System.currentTimeMillis());
|
||||
}
|
||||
|
||||
public long getLastQueryTime() {
|
||||
return lastQueryTime;
|
||||
}
|
||||
|
||||
public Snapshot getSnapshot(boolean reset) {
|
||||
// not guaranteed to be consistent - time gaps between getting each value
|
||||
if (reset) {
|
||||
return new Snapshot(queryPlan, count.sumThenReset(), totalTime.sumThenReset(), totalBeans.sumThenReset(), maxTime.getAndSet(0), startTime.getAndSet(System.currentTimeMillis()), lastQueryTime);
|
||||
}
|
||||
return new Snapshot(queryPlan, count.sum(), totalTime.sum(), totalBeans.sum(), maxTime.get(), startTime.get(), lastQueryTime);
|
||||
}
|
||||
|
||||
/**
|
||||
* A snapshot of the current statistics for a query plan.
|
||||
*/
|
||||
public static class Snapshot implements MetaBeanQueryPlanStatistic {
|
||||
|
||||
private final CQueryPlan queryPlan;
|
||||
private final long count;
|
||||
private final long totalTime;
|
||||
private final long totalBeans;
|
||||
private final long maxTime;
|
||||
private final long startTime;
|
||||
private final long lastQueryTime;
|
||||
|
||||
public Snapshot(CQueryPlan queryPlan, long count, long totalTime, long totalBeans, long maxTime, long startTime, long lastQueryTime) {
|
||||
super();
|
||||
this.queryPlan = queryPlan;
|
||||
this.count = count;
|
||||
this.totalTime = totalTime;
|
||||
this.totalBeans = totalBeans;
|
||||
this.maxTime = maxTime;
|
||||
this.startTime = startTime;
|
||||
this.lastQueryTime = lastQueryTime;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return queryPlan+" count:"+count+" time:"+totalTime+" maxTime:"+maxTime+" beans:"+totalBeans+" start:"+startTime+" lastQuery:"+lastQueryTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Class<?> getBeanType() {
|
||||
return queryPlan.getBeanType();
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getExecutionCount() {
|
||||
return count;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getTotalTimeMicros() {
|
||||
return totalTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getTotalLoadedBeans() {
|
||||
return totalBeans;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getMaxTimeMicros() {
|
||||
return maxTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getCollectionStart() {
|
||||
return startTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getLastQueryTime() {
|
||||
return lastQueryTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isAutofetchTuned() {
|
||||
return queryPlan.isAutofetchTuned();
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public int getQueryPlanHash() {
|
||||
return queryPlan.getHash();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getSql() {
|
||||
return queryPlan.getSql();
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getAvgTimeMicros() {
|
||||
return count < 1 ? 0 : totalTime / count;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getAvgLoadedBeans() {
|
||||
return count < 1 ? 0 : totalBeans / count;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
|
||||
package com.avaje.ebeaninternal.server.query;
|
||||
|
||||
import com.avaje.ebean.meta.MetaQueryStatistic;
|
||||
|
||||
/**
|
||||
* Statistics for query plan that can accumulate.
|
||||
*/
|
||||
public final class CQueryStats {
|
||||
|
||||
private final int count;
|
||||
|
||||
private final int totalLoadedBeanCount;
|
||||
|
||||
private final int totalTimeMicros;
|
||||
|
||||
private final long startCollecting;
|
||||
|
||||
private final long lastQueryTime;
|
||||
|
||||
public CQueryStats() {
|
||||
count = 0;
|
||||
totalLoadedBeanCount = 0;
|
||||
totalTimeMicros = 0;
|
||||
startCollecting = System.currentTimeMillis();
|
||||
lastQueryTime = 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Accumulate/Increment the statistics based on the previous statistics.
|
||||
*/
|
||||
public CQueryStats(CQueryStats previous, int loadedBeanCount, int timeMicros) {
|
||||
count = previous.count + 1;
|
||||
totalLoadedBeanCount = previous.totalLoadedBeanCount + loadedBeanCount;
|
||||
totalTimeMicros = previous.totalTimeMicros + timeMicros;
|
||||
startCollecting = previous.startCollecting;
|
||||
lastQueryTime = System.currentTimeMillis();
|
||||
}
|
||||
|
||||
public CQueryStats add(int loadedBeanCount, int timeMicros) {
|
||||
return new CQueryStats(this, loadedBeanCount, timeMicros);
|
||||
}
|
||||
|
||||
public int getCount() {
|
||||
return count;
|
||||
}
|
||||
|
||||
public int getAverageTimeMicros() {
|
||||
if (count == 0) {
|
||||
return 0;
|
||||
} else {
|
||||
return totalTimeMicros / count;
|
||||
}
|
||||
}
|
||||
|
||||
public int getTotalLoadedBeanCount() {
|
||||
return totalLoadedBeanCount;
|
||||
}
|
||||
|
||||
public int getTotalTimeMicros() {
|
||||
return totalTimeMicros;
|
||||
}
|
||||
|
||||
public long getStartCollecting() {
|
||||
return startCollecting;
|
||||
}
|
||||
|
||||
public long getLastQueryTime() {
|
||||
return lastQueryTime;
|
||||
}
|
||||
|
||||
public MetaQueryStatistic createMetaQueryStatistic(String beanName, CQueryPlan qp) {
|
||||
return new MetaQueryStatistic(qp.isAutofetchTuned(), beanName, qp.getHash(),
|
||||
qp.getSql(), count, totalLoadedBeanCount, totalTimeMicros, startCollecting, lastQueryTime);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -83,7 +83,7 @@ public class RawSqlSelectClauseBuilder {
|
||||
|
||||
SqlTree sqlTree = sqlSelect.getSqlTree();
|
||||
|
||||
CQueryPlan queryPlan = new CQueryPlan(sql, sqlTree, true, includeRowNumColumn, "");
|
||||
CQueryPlan queryPlan = new CQueryPlan(query.getBeanType(), sql, sqlTree, true, includeRowNumColumn, "");
|
||||
CQuery<T> compiledQuery = new CQuery<T>(request, predicates, queryPlan);
|
||||
|
||||
return compiledQuery;
|
||||
|
||||
Reference in new issue
Block a user