MCPcopy Create free account
hub / github.com/apple/foundationdb / init

Method init

fdbclient/BlobGranuleFiles.cpp:327–341  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

325 }
326
327 void init(Optional<BlobGranuleCipherKeysCtx> cipherKeysCtx, Arena& arena) {
328 if (encryptHeaderRef.present()) {
329 CODE_PROBE(true, "reading encrypted chunked file");
330 ASSERT(cipherKeysCtx.present());
331
332 decrypt(cipherKeysCtx.get(), *this, arena);
333 } else {
334 if (BG_ENCRYPT_COMPRESS_DEBUG) {
335 TraceEvent("IndexBlockSize").detail("Sz", buffer.size());
336 }
337
338 ObjectReader dataReader(buffer.begin(), IncludeVersion());
339 dataReader.deserialize(FileIdentifierFor<IndexBlock>::value, block, arena);
340 }
341 }
342
343 void finalize(Optional<BlobGranuleCipherKeysCtx> cipherKeysCtx, Arena& arena) {
344 if (cipherKeysCtx.present()) {

Callers 4

initMethod · 0.45
fromFileBytesMethod · 0.45
serializeChunkedSnapshotFunction · 0.45

Calls 8

TraceEventClass · 0.85
IncludeVersionFunction · 0.85
detailMethod · 0.80
getMethod · 0.65
presentMethod · 0.45
sizeMethod · 0.45
beginMethod · 0.45
deserializeMethod · 0.45

Tested by

no test coverage detected