From cb193f15ffd443cdb370a43e97712bd4b4b83edf Mon Sep 17 00:00:00 2001 From: Geir Storli Date: Wed, 17 Nov 2021 15:56:28 +0000 Subject: 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). --- searchcorespi/src/vespa/searchcorespi/index/ithreadingservice.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'searchcorespi') 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; -- cgit v1.2.3