You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by bb...@apache.org on 2019/08/20 10:02:33 UTC
[mesos] 03/07: Updated config factory to set resource provider
reconciliation interval.
This is an automated email from the ASF dual-hosted git repository.
bbannier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mesos.git
commit 6e8ddb00025b0c353604d7d7db691fb99b53d2c6
Author: Benjamin Bannier <bb...@apache.org>
AuthorDate: Wed Aug 14 09:33:23 2019 +0200
Updated config factory to set resource provider reconciliation interval.
Review: https://reviews.apache.org/r/71147/
---
src/tests/storage_local_resource_provider_tests.cpp | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/src/tests/storage_local_resource_provider_tests.cpp b/src/tests/storage_local_resource_provider_tests.cpp
index 8b9009c..66c31eb 100644
--- a/src/tests/storage_local_resource_provider_tests.cpp
+++ b/src/tests/storage_local_resource_provider_tests.cpp
@@ -63,6 +63,8 @@
#include "messages/messages.hpp"
+#include "resource_provider/constants.hpp"
+
#include "slave/container_daemon_process.hpp"
#include "slave/paths.hpp"
#include "slave/state.hpp"
@@ -94,6 +96,8 @@ using mesos::internal::slave::ContainerDaemonProcess;
using mesos::master::detector::MasterDetector;
using mesos::master::detector::StandaloneMasterDetector;
+using mesos::resource_provider::DEFAULT_STORAGE_RECONCILIATION_INTERVAL;
+
using process::Clock;
using process::Future;
using process::Owned;
@@ -246,7 +250,8 @@ public:
const Option<string>& volumes = None(),
const Option<string>& forward = None(),
const Option<string>& createParameters = None(),
- const Option<string>& volumeMetadata = None())
+ const Option<string>& volumeMetadata = None(),
+ const Option<Duration>& reconciliationInterval = None())
{
const string testCsiPluginPath =
path::join(tests::flags.build_dir, "src", "test-csi-plugin");
@@ -304,7 +309,8 @@ public:
]
}
]
- }
+ },
+ "reconciliation_interval_seconds" : %s
}
}
)~",
@@ -320,7 +326,10 @@ public:
volumes.getOrElse(""),
forward.isSome() ? "--forward=" + forward.get() : "",
createParameters.getOrElse(""),
- volumeMetadata.getOrElse(""));
+ volumeMetadata.getOrElse(""),
+ stringify(reconciliationInterval
+ .getOrElse(DEFAULT_STORAGE_RECONCILIATION_INTERVAL)
+ .secs()));
ASSERT_SOME(resourceProviderConfig);