beegfs/meta/source/toolkit/BuddyCommTk.h
2025-08-10 01:34:16 +02:00

26 lines
738 B
C++

#pragma once
#include <string>
#include <common/storage/StorageErrors.h>
#include <common/nodes/NumNodeID.h>
class MirrorBuddyGroupMapper;
class TimerQueue;
/**
* This contains all the functions regarding the communication with the mirror buddy.
* In the storage server, these mostly live in the StorageTargets class, but because the metadata
* server only has a single metadata target at the moment, we group them here.
*/
namespace BuddyCommTk
{
void prepareBuddyNeedsResyncState(Node& mgmtNode, const MirrorBuddyGroupMapper& bgm,
TimerQueue& timerQ, NumNodeID localNodeID);
void checkBuddyNeedsResync();
void setBuddyNeedsResync(const std::string& path, bool needsResync);
bool getBuddyNeedsResync();
};