build_script: |
sudo -E -u nobody make -C build -j2 all
test_script: |
+ sysctl net.inet.tcp.msl=500
sudo -E -u nobody make -C build -j2 test/fast
install_script: |
sudo -E -u nobody make -C build install DESTDIR=/tmp
return started;
}
-void Cluster::stop() {
+void Cluster::stop(bool graceful) {
for (auto &server : cluster) {
server.drain();
- // no cookies for memcached; TERM is just too slow
- server.signal(SIGKILL);
+ if (graceful) {
+ server.stop();
+ } else {
+ // no cookies for memcached; TERM is just too slow
+ server.signal(SIGKILL);
+ }
}
}
const vector<Server> &getServers() const;
bool start();
- void stop();
+ void stop(bool graceful = false);
bool isStopped();
bool isListening();
void wait();
REQUIRE_SUCCESS(memcached_set(memc, S("foo"), nullptr, 0, 0, 0));
memcached_quit(memc);
- test.cluster.stop();
+ test.cluster.stop(
+#if __FreeBSD__
+ true // graceful
+#endif
+ );
Retry cluster_is_stopped{[&cluster = test.cluster]{
return cluster.isStopped();
}};