aboutsummaryrefslogtreecommitdiffstats
path: root/searchcorespi
diff options
context:
space:
mode:
authorGeir Storli <geirst@verizonmedia.com>2021-11-17 15:56:28 +0000
committerGeir Storli <geirst@verizonmedia.com>2021-11-17 15:59:16 +0000
commitcb193f15ffd443cdb370a43e97712bd4b4b83edf (patch)
tree389b23f151082b1f45ef3a5c70614b613032d407 /searchcorespi
parent65fe0e9b45b10e9b3663a729969473d84f3b5edd (diff)
Add support for blocking external feed operations when the document db master thread has reached its task limit.
Turning this functionality on/off is controlled by proton config (default off).
Diffstat (limited to 'searchcorespi')
-rw-r--r--searchcorespi/src/vespa/searchcorespi/index/ithreadingservice.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/searchcorespi/src/vespa/searchcorespi/index/ithreadingservice.h b/searchcorespi/src/vespa/searchcorespi/index/ithreadingservice.h
index f30aec94d53..0660f3ab495 100644
--- a/searchcorespi/src/vespa/searchcorespi/index/ithreadingservice.h
+++ b/searchcorespi/src/vespa/searchcorespi/index/ithreadingservice.h
@@ -65,6 +65,12 @@ struct IThreadingService
virtual void sync_all_executors() = 0;
+ /**
+ * Block the calling thread until the master thread has capacity to handle more tasks,
+ * and then execute the given task in the master thread.
+ */
+ virtual void blocking_master_execute(vespalib::Executor::Task::UP task) = 0;
+
virtual IThreadService &master() = 0;
virtual IThreadService &index() = 0;
virtual IThreadService &summary() = 0;