aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2023-05-12 11:08:34 +0000
committerHenning Baldersheim <balder@yahoo-inc.com>2023-05-12 11:08:34 +0000
commitcb7330a28a940741fbddaeec622da0555ef93ec9 (patch)
treebc2dadbe6bbbe6a8857fada04574b975cb3ac0b1
parentd07eafbbea7c0080e4c77129421b0ef6d6334e9d (diff)
Only consider the next target in the Q for high priority flush.
-rw-r--r--searchcore/src/vespa/searchcore/proton/flushengine/flushengine.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/flushengine/flushengine.cpp b/searchcore/src/vespa/searchcore/proton/flushengine/flushengine.cpp
index 2d47ea8fb4e..1916a324c6e 100644
--- a/searchcore/src/vespa/searchcore/proton/flushengine/flushengine.cpp
+++ b/searchcore/src/vespa/searchcore/proton/flushengine/flushengine.cpp
@@ -199,10 +199,8 @@ FlushEngine::checkAndFlush(vespalib::string prev) {
prev = flushNextTarget(prev, lst.first);
} else {
FlushContext::List highPri;
- for (const FlushContext::SP & ctx : lst.first) {
- if (ctx->getTarget()->getPriority() > IFlushTarget::Priority::NORMAL) {
- highPri.push_back(ctx);
- }
+ if (lst.first.front()->getTarget()->getPriority() > IFlushTarget::Priority::NORMAL) {
+ highPri.push_back(lst.first.front());
}
prev = flushNextTarget(prev, highPri);
}