os/ObjectStore: add has_contexts()

Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
Sage Weil 2018-04-02 20:57:04 -05:00
parent 0724072b16
commit b85a24acd1

View File

@ -522,6 +522,12 @@ public:
register_on_applied(new ContainerContext<RunOnDeleteRef>(_complete));
register_on_commit(new ContainerContext<RunOnDeleteRef>(_complete));
}
bool has_contexts() const {
return
!on_commit.empty() ||
!on_applied.empty() ||
!on_applied_sync.empty();
}
static void collect_contexts(
vector<Transaction>& t,