aboutsummaryrefslogtreecommitdiff
path: root/src/zenstore/filecas.h
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2024-11-22 10:58:20 +0100
committerGitHub Enterprise <[email protected]>2024-11-22 10:58:20 +0100
commit36658631e3f29b27d08b36fa6cf143d6902b7789 (patch)
tree8c618ec8081a40a479dc98dfd91b96b8b1e21e9c /src/zenstore/filecas.h
parentfixed off-by-one in GetPidStatus (Linux) which might cause spurious errors (#... (diff)
downloadzen-36658631e3f29b27d08b36fa6cf143d6902b7789.tar.xz
zen-36658631e3f29b27d08b36fa6cf143d6902b7789.zip
fix inconsistencies in filecas due to failing to remove payload file during GC (#224)
make sure we rewrite filecas entries if chunk size changes (due to compression changes) hardening of move/write files in filecas if we encounter a filecas entry with mismatching size (due to pre-existing bug) we validate the file and update the index if we find a bad filecas file on disk we now attempt to remove it
Diffstat (limited to 'src/zenstore/filecas.h')
-rw-r--r--src/zenstore/filecas.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/zenstore/filecas.h b/src/zenstore/filecas.h
index ff7126325..fb4b1888b 100644
--- a/src/zenstore/filecas.h
+++ b/src/zenstore/filecas.h
@@ -61,8 +61,6 @@ private:
};
using IndexMap = tsl::robin_map<IoHash, IndexEntry, IoHash::Hasher>;
- CasStore::InsertResult InsertChunkData(const void* ChunkData, size_t ChunkSize, const IoHash& ChunkHash);
-
LoggerRef m_Log;
GcManager& m_Gc;
std::filesystem::path m_RootDirectory;
@@ -103,6 +101,8 @@ private:
ExtendablePathBuilder<128> ShardedPath;
};
+ bool UpdateIndex(const IoHash& ChunkHash, uint64_t ChunkSize);
+
friend class FileCasReferencePruner;
friend class FileCasStoreCompactor;
};