提交 ba7ba113 authored 作者: S.Vladykin's avatar S.Vladykin

Sub-query cache is getting dropped in finally block.

上级 6dff38d0
...@@ -482,9 +482,12 @@ public class Session extends SessionWithState { ...@@ -482,9 +482,12 @@ public class Session extends SessionWithState {
} }
} }
Parser parser = new Parser(this); Parser parser = new Parser(this);
command = parser.prepareCommand(sql); try {
// we can't reuse view indexes from sub-queries, so just drop the cache command = parser.prepareCommand(sql);
subQueryIndexCache = null; } finally {
// we can't reuse sub-query indexes, so just drop the whole cache
subQueryIndexCache = null;
}
if (queryCache != null) { if (queryCache != null) {
if (command.isCacheable()) { if (command.isCacheable()) {
queryCache.put(sql, command); queryCache.put(sql, command);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论