#pragma once #include #include #include #include #include // Update entry info, called by fsck or by fhgfs-ctl class RefreshEntryInfoMsgEx : public MirroredMessage> { public: typedef ErrorCodeResponseState ResponseState; virtual bool processIncoming(ResponseContext& ctx) override; std::tuple lock(EntryLockStore& store) override; bool isMirrored() override { return getEntryInfo()->getIsBuddyMirrored(); } private: std::unique_ptr executeLocally(ResponseContext& ctx, bool isSecondary) override; FhgfsOpsErr refreshInfoRec(); FhgfsOpsErr refreshInfoRoot(); void forwardToSecondary(ResponseContext& ctx) override; FhgfsOpsErr processSecondaryResponse(NetMessage& resp) override { return (FhgfsOpsErr) static_cast(resp).getValue(); } const char* mirrorLogContext() const override { return "RefreshEntryInfoMsgEx/forward"; } };