summaryrefslogtreecommitdiffstats
path: root/searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h
diff options
context:
space:
mode:
Diffstat (limited to 'searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h')
-rw-r--r--searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h b/searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h
index 113aae8c9bf..baf0e98d5a4 100644
--- a/searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h
+++ b/searchcore/src/vespa/searchcore/proton/server/operationdonecontext.h
@@ -4,6 +4,8 @@
#include <vespa/vespalib/util/idestructorcallback.h>
+namespace proton::feedtoken { class IState; }
+
namespace proton {
/**
@@ -16,13 +18,13 @@ namespace proton {
class OperationDoneContext : public vespalib::IDestructorCallback
{
public:
- using IDestructorCallback = vespalib::IDestructorCallback;
- OperationDoneContext(IDestructorCallback::SP token);
+ OperationDoneContext(std::shared_ptr<feedtoken::IState> token, std::shared_ptr<IDestructorCallback> done_callback);
~OperationDoneContext() override;
- bool hasToken() const { return static_cast<bool>(_token); }
+ bool is_replay() const;
private:
- IDestructorCallback::SP _token;
+ std::shared_ptr<feedtoken::IState> _token;
+ std::shared_ptr<vespalib::IDestructorCallback> _done_callback;
};
} // namespace proton