diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2016-09-13 13:12:40 +0000 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2016-09-14 09:16:51 +0000 |
commit | 3595bceabff604bfce8588b5dc7dbc2fbccd2aef (patch) | |
tree | 04fce0823f098101d19ed2d80945c61d91656729 /filedistribution/src/apps/filedistributor | |
parent | 6b228b92b44c473c773011cb043c10177b95bf66 (diff) |
boost::this_thread::sleep -> std::this_thread::sleep_for
Diffstat (limited to 'filedistribution/src/apps/filedistributor')
-rw-r--r-- | filedistribution/src/apps/filedistributor/filedistributor.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/filedistribution/src/apps/filedistributor/filedistributor.cpp b/filedistribution/src/apps/filedistributor/filedistributor.cpp index 7387d12245b..11b2844e95f 100644 --- a/filedistribution/src/apps/filedistributor/filedistributor.cpp +++ b/filedistribution/src/apps/filedistributor/filedistributor.cpp @@ -38,6 +38,7 @@ const char* programName = "filedistributor"; LOG_SETUP(programName); namespace ll = boost::lambda; +using namespace std::literals; using namespace filedistribution; using cloud::config::ZookeepersConfig; @@ -200,10 +201,8 @@ public: static void ensureExceptionsStored(const std::shared_ptr<ExceptionRethrower>& exceptionRethrower) { //TODO: this is somewhat hackish, refactor to eliminate this later. LOG(debug, "Waiting for shutdown"); - for (int i=0; - i<50 && !exceptionRethrower.unique(); - ++i) { - boost::this_thread::sleep(boost::posix_time::milliseconds(100)); + for (int i=0; i<50 && !exceptionRethrower.unique(); ++i) { + std::this_thread::sleep_for(100ms); } LOG(debug, "Done waiting for shutdown"); @@ -261,7 +260,7 @@ public: !completeReconfigurationNeeded() && !_exceptionRethrower->exceptionStored()) { postPoneAskedToReinitializedSecs--; - boost::this_thread::sleep(boost::posix_time::seconds(1)); + std::this_thread::sleep_for(1s); } } }; |