diff options
Diffstat (limited to 'zenserver/projectstore.h')
| -rw-r--r-- | zenserver/projectstore.h | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/zenserver/projectstore.h b/zenserver/projectstore.h index 38c53ea6e..72b8a1cd6 100644 --- a/zenserver/projectstore.h +++ b/zenserver/projectstore.h @@ -99,6 +99,12 @@ public: uint64_t Size; }; + struct FileMapEntry + { + std::string ServerPath; + std::string ClientPath; + }; + template<class V> using OidMap = tsl::robin_map<Oid, V, Oid::Hasher>; @@ -108,18 +114,17 @@ public: std::filesystem::path m_BasePath; std::filesystem::path m_TempPath; - OidMap<IoHash> m_ChunkMap; // output data chunk id -> CAS address - OidMap<IoHash> m_MetaMap; // meta chunk id -> CAS address - OidMap<std::string> m_FileMap; // file id -> client file - OidMap<std::string> m_ServerFileMap; // file id -> server file - std::map<int, OplogEntryAddress> m_OpAddressMap; // Index LSN -> op data in ops blob file - OidMap<int> m_LatestOpMap; // op key -> latest op LSN for key + OidMap<IoHash> m_ChunkMap; // output data chunk id -> CAS address + OidMap<IoHash> m_MetaMap; // meta chunk id -> CAS address + OidMap<FileMapEntry> m_FileMap; // file id -> file map entry + int32_t m_ManifestVersion; // File system manifest version + std::map<int, OplogEntryAddress> m_OpAddressMap; // Index LSN -> op data in ops blob file + OidMap<int> m_LatestOpMap; // op key -> latest op LSN for key RefPtr<OplogStorage> m_Storage; std::string m_OplogId; - void AddFileMapping(Oid FileId, std::string_view Path); - void AddServerFileMapping(Oid FileId, std::string_view Path); + bool AddFileMapping(Oid FileId, IoHash Hash, std::string_view ServerPath, std::string_view ClientPath); void AddChunkMapping(Oid ChunkId, IoHash Hash); void AddMetaMapping(Oid ChunkId, IoHash Hash); }; |