File tree Expand file tree Collapse file tree 3 files changed +6
-11
lines changed
mcrouter/lib/network/test Expand file tree Collapse file tree 3 files changed +6
-11
lines changed Original file line number Diff line number Diff line change 1313#include < glog/logging.h>
1414
1515#include < folly/Format.h>
16- #include < folly/Singleton .h>
16+ #include < folly/init/Init .h>
1717#include < folly/logging/Init.h>
1818
1919#include " mcrouter/lib/network/AsyncMcServer.h"
2020#include " mcrouter/lib/network/AsyncMcServerWorker.h"
21- #include " mcrouter/lib/network/CarbonMessageDispatcher.h"
2221#include " mcrouter/lib/network/McServerRequestContext.h"
23- #include " mcrouter/lib/network/gen/MemcacheMessages.h"
2422#include " mcrouter/lib/network/gen/MemcacheServer.h"
25- #include " mcrouter/lib/network/test/MockMc.h"
2623#include " mcrouter/lib/network/test/MockMcOnRequest.h"
2724
2825/* *
@@ -70,7 +67,7 @@ void serverLoop(
7067FOLLY_INIT_LOGGING_CONFIG (" .=WARNING,folly=INFO; default:async=true" );
7168
7269int main (int argc, char ** argv) {
73- folly::SingletonVault::singleton ()-> registrationComplete ( );
70+ folly::Init init (&argc, &argv, folly::InitOptions{}. useGFlags ( false ). removeFlags ( false ) );
7471
7572 AsyncMcServer::Options opts;
7673 opts.worker .versionString = " MockMcServer-1.0" ;
Original file line number Diff line number Diff line change 1313#include < glog/logging.h>
1414
1515#include < folly/Format.h>
16- #include < folly/Singleton.h>
1716#include < folly/executors/IOThreadPoolExecutor.h>
17+ #include < folly/init/Init.h>
1818#include < folly/io/async/AsyncSignalHandler.h>
1919#include < folly/io/async/EventBase.h>
2020#include < folly/logging/Init.h>
2323#include " mcrouter/ExecutorObserver.h"
2424#include " mcrouter/lib/network/AsyncMcServer.h"
2525#include " mcrouter/lib/network/AsyncMcServerWorker.h"
26- #include " mcrouter/lib/network/CarbonMessageDispatcher.h"
27- #include " mcrouter/lib/network/McServerRequestContext.h"
2826#include " mcrouter/lib/network/ServerLoad.h"
2927#include " mcrouter/lib/network/test/MockMcThriftServerHandler.h"
3028
@@ -98,7 +96,7 @@ class ShutdownSignalHandler : public folly::AsyncSignalHandler {
9896};
9997
10098int main (int argc, char ** argv) {
101- folly::SingletonVault::singleton ()-> registrationComplete ( );
99+ folly::Init init (&argc, &argv, folly::InitOptions{}. useGFlags ( false ). removeFlags ( false ) );
102100
103101 AsyncMcServer::Options asyncOpts;
104102 asyncOpts.worker .versionString = " MockMcServer-1.0" ;
Original file line number Diff line number Diff line change 1313#include < glog/logging.h>
1414
1515#include < folly/Format.h>
16- #include < folly/Singleton .h>
16+ #include < folly/init/Init .h>
1717#include < folly/logging/Init.h>
1818#include < thrift/lib/cpp2/server/ThriftServer.h>
1919
@@ -52,7 +52,7 @@ void sigHandler(int /* signo */) {
5252}
5353
5454int main (int argc, char ** argv) {
55- folly::SingletonVault::singleton ()-> registrationComplete ( );
55+ folly::Init init (&argc, &argv, folly::InitOptions{}. useGFlags ( false ). removeFlags ( false ) );
5656
5757 uint16_t port = 0 ;
5858 int existingSocketFd = 0 ;
You can’t perform that action at this time.
0 commit comments