swap.state File Structure
Collaboration diagram for swap.state File Structure:

Classes

class  StoreSwapLogHeader
 

Detailed Description

Implementation Notes

When writing an object to disk, we must first write the meta data. This is done with a couple of functions. First, storeSwapMetaPack() takes a StoreEntry as a parameter and returns a tlv linked list. Second, storeSwapMetaPack() converts the tlv list into a character buffer that we can write.
Note
MemObject has a MemObject::swap_hdr_sz. This value is the size of that character buffer; the size of the swap file meta data. The StoreEntry has a member StoreEntry::swap_file_sz that represents the size of the disk file. Thus, the size of the object "content" is
The swap file content includes the HTTP reply headers and the HTTP reply body (if any).
When reading a swap file, there is a similar process to extract the swap meta data. First, storeSwapMetaUnpack() converts a character buffer into a tlv linked list. It also tells us the value for MemObject->swap_hdr_sz.

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors