aboutsummaryrefslogtreecommitdiffstats
path: root/searchcore/src/vespa/searchcorespi/index/warmupconfig.h
diff options
context:
space:
mode:
Diffstat (limited to 'searchcore/src/vespa/searchcorespi/index/warmupconfig.h')
-rw-r--r--searchcore/src/vespa/searchcorespi/index/warmupconfig.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/searchcore/src/vespa/searchcorespi/index/warmupconfig.h b/searchcore/src/vespa/searchcorespi/index/warmupconfig.h
new file mode 100644
index 00000000000..8582b7256bc
--- /dev/null
+++ b/searchcore/src/vespa/searchcorespi/index/warmupconfig.h
@@ -0,0 +1,22 @@
+// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
+#pragma once
+
+#include <vespa/vespalib/util/time.h>
+
+namespace searchcorespi::index {
+
+/**
+ * Keeps all config for controlling warmup.
+ **/
+class WarmupConfig {
+public:
+ WarmupConfig() : _duration(vespalib::duration::zero()), _unpack(false) { }
+ WarmupConfig(vespalib::duration duration, bool unpack) : _duration(duration), _unpack(unpack) { }
+ vespalib::duration getDuration() const { return _duration; }
+ bool getUnpack() const { return _unpack; }
+private:
+ const vespalib::duration _duration;
+ const bool _unpack;
+};
+
+}