RockRebuild.h
Go to the documentation of this file.
88 void primeNewEntry(Ipc::StoreMapAnchor &anchor, const sfileno fileno, const DbCellHeader &header);
Definition: AsyncJob.h:32
A RegisteredRunner with lifetime determined by forces outside the Registry.
Definition: RunnersRegistry.h:107
Definition: Pointer.h:26
Definition: Pointer.h:83
Definition: StoreMap.h:57
Definition: MemBuf.h:24
Definition: RockDbCell.h:23
smart StoreEntry-level info pointer (hides anti-padding LoadingParts arrays)
Definition: RockRebuild.cc:110
Definition: RockRebuild.cc:162
smart db slot-level info pointer (hides anti-padding LoadingParts arrays)
Definition: RockRebuild.cc:134
cache_dir indexing statistics shared across same-kid process restarts
Definition: RockRebuild.h:37
static Ipc::Mem::Owner< Stats > * Init(const SwapDir &)
Definition: RockRebuild.cc:257
bool completed(const SwapDir &) const
whether the rebuild is finished already
Definition: RockRebuild.cc:263
Definition: RockRebuild.h:31
void freeBadEntry(const sfileno fileno, const char *eDescription)
Definition: RockRebuild.cc:670
void validateOneSlot(const SlotId slotId)
Definition: RockRebuild.cc:660
void finalizeOrThrow(const sfileno fileNo, LoadingEntry &le)
Definition: RockRebuild.cc:598
void freeSlot(const SlotId slotId, const bool invalid)
adds slot to the free slot index
Definition: RockRebuild.cc:714
void primeNewEntry(Ipc::StoreMapAnchor &anchor, const sfileno fileno, const DbCellHeader &header)
initialize housekeeping information for a newly accepted entry
Definition: RockRebuild.cc:830
void addSlotToEntry(const sfileno fileno, const SlotId slotId, const DbCellHeader &header)
Definition: RockRebuild.cc:770
void mapSlot(const SlotId slotId, const DbCellHeader &header)
adds slot to the entry chain in the map
Definition: RockRebuild.cc:744
LoadingEntry loadingEntry(const sfileno fileNo)
Definition: RockRebuild.cc:453
LoadingSlot loadingSlot(const SlotId slotId)
Definition: RockRebuild.cc:460
void chainSlots(SlotIdType &from, const SlotId to)
Definition: RockRebuild.cc:759
void validateOneEntry(const sfileno fileNo)
Definition: RockRebuild.cc:642
Rebuild(SwapDir *dir, const Ipc::Mem::Pointer< Stats > &)
Definition: RockRebuild.cc:298
bool importEntry(Ipc::StoreMapAnchor &anchor, const sfileno slotId, const DbCellHeader &header)
parse StoreEntry basics and add them to the map, returning true on success
Definition: RockRebuild.cc:530
void startNewEntry(const sfileno fileno, const SlotId slotId, const DbCellHeader &header)
handle a slot from an entry that we have not seen before
Definition: RockRebuild.cc:846
static bool IsResponsible(const SwapDir &)
whether the current kid is responsible for rebuilding the given cache_dir
Definition: RockRebuild.cc:272
void useNewSlot(const SlotId slotId, const DbCellHeader &header)
handle freshly loaded (and validated) db slot header
Definition: RockRebuild.cc:876
bool sameEntry(const sfileno fileno, const DbCellHeader &header) const
does the header belong to the fileno entry being loaded?
Definition: RockRebuild.cc:866
void freeUnusedSlot(const SlotId slotId, const bool invalid)
freeSlot() for never-been-mapped slots
Definition: RockRebuild.cc:734
CBDATA_CHILD(Rebuild)
void finalizeOrFree(const sfileno fileNo, LoadingEntry &le)
Definition: RockRebuild.cc:632
Definition: RockSwapDir.h:33
Definition: forward.h:28
sfileno SlotId
db cell number, starting with cell 0 (always occupied by the db header)
Definition: forward.h:33