diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2016-09-15 07:58:48 +0000 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2016-09-15 07:58:48 +0000 |
commit | 090273a07b00760a2b96c5de2becbb93a529dda4 (patch) | |
tree | 5391ddab3d494a50e284a8a9f9c70394a281b9ca /filedistribution | |
parent | 9a79125352dd793435960c773f144aa38860512e (diff) |
Assert when closing down.
Diffstat (limited to 'filedistribution')
-rw-r--r-- | filedistribution/src/vespa/filedistribution/common/componentsdeleter.cpp | 13 | ||||
-rw-r--r-- | filedistribution/src/vespa/filedistribution/common/componentsdeleter.h | 1 |
2 files changed, 2 insertions, 12 deletions
diff --git a/filedistribution/src/vespa/filedistribution/common/componentsdeleter.cpp b/filedistribution/src/vespa/filedistribution/common/componentsdeleter.cpp index 053073b26e5..3c6a265941a 100644 --- a/filedistribution/src/vespa/filedistribution/common/componentsdeleter.cpp +++ b/filedistribution/src/vespa/filedistribution/common/componentsdeleter.cpp @@ -48,8 +48,8 @@ ComponentsDeleter::waitForAllComponentsDeleted() std::this_thread::sleep_for(100ms); } LOG(debug, "Done waiting for all components to be deleted"); - - logNotDeletedComponents(); + assert(_trackedComponents.empty()); + assert(_deleteRequests.empty()); } void @@ -70,15 +70,6 @@ ComponentsDeleter::areWeDone() } void -ComponentsDeleter::logNotDeletedComponents() -{ - LockGuard guard(_trackedComponentsMutex); - for (const auto & component : _trackedComponents) { - LOG(info, "Timed out waiting for component '%s' to be deleted", component.second.c_str()); - } -} - -void ComponentsDeleter::removeFromTrackedComponents(void* component) { LockGuard guard(_trackedComponentsMutex); if (_trackedComponents.count(component)) diff --git a/filedistribution/src/vespa/filedistribution/common/componentsdeleter.h b/filedistribution/src/vespa/filedistribution/common/componentsdeleter.h index 277084e28b3..46d79663536 100644 --- a/filedistribution/src/vespa/filedistribution/common/componentsdeleter.h +++ b/filedistribution/src/vespa/filedistribution/common/componentsdeleter.h @@ -44,7 +44,6 @@ class ComponentsDeleter { void waitForAllComponentsDeleted(); bool areWeDone(); - void logNotDeletedComponents(); void close(); public: ComponentsDeleter(const ComponentsDeleter &) = delete; |