mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#1061 - findCount query is not cached in L2 query cache
This commit is contained in:
@@ -70,7 +70,11 @@ public class DefaultOrmQueryEngine implements OrmQueryEngine {
|
||||
public <T> int findCount(OrmQueryRequest<T> request) {
|
||||
|
||||
flushJdbcBatchOnQuery(request);
|
||||
return queryEngine.findCount(request);
|
||||
int result = queryEngine.findCount(request);
|
||||
if (request.getQuery().isUseQueryCache()) {
|
||||
request.putToQueryCache(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user