thrift.transport.file

Transports for reading from/writing to Thrift »log files«.

These transports are not »stupid« sources and sinks just reading and writing bytes from a file verbatim, but organize the contents in the form of so-called »events«, which refers to the data written between two flush() calls.

Chunking is supported, events are guaranteed to never span chunk boundaries. As a consequence, an event can never be larger than the chunk size. The chunk size used is not saved with the file, so care has to be taken to make sure the same chunk size is used for reading and writing.

Members

Aliases

EventSize
alias EventSize = uint

The type used to represent event sizes in the file.

Classes

TFileReaderTransport
class TFileReaderTransport

A transport used to read log files. It can never be written to, calling write() throws.

TFileWriterTransport
class TFileWriterTransport

A transport used to write log files. It can never be read from, calling read() throws.

Manifest constants

DEFAULT_CHUNK_SIZE
enum DEFAULT_CHUNK_SIZE;

The default chunk size, in bytes.

Meta