Table of Contents

Namespace RocksDbNet

Classes

ApproximateMemoryUsage

How much memory a set of databases and caches is using, at one moment.

BackgroundErrorInfo

Information about a background error.

BackupEngine

Manages backups of a RocksDb database. Maps to rocksdb_backup_engine_t.

BackupEngineOptions

Options for opening a BackupEngine. Maps to rocksdb_backup_engine_options_t.

BackupInfo

Metadata for a single backup entry.

BlobFileAdditionInfo

A blob file created by a flush or compaction. Maps to rocksdb_blob_file_addition_info_t.

BlobFileGarbageInfo

Garbage discovered in a blob file during compaction. Maps to rocksdb_blob_file_garbage_info_t.

BlockBasedTableOptions

Options for the block-based table format. Configure and then pass to BlockBasedTableFactory. Maps to rocksdb_block_based_table_options_t.

Cache

An LRU or HyperClock block/row cache. Maps to rocksdb_cache_t.

CallbackExceptionEventArgs

Describes an exception that escaped a managed callback invoked by native RocksDb code.

Checkpoint

Creates on-disk checkpoints (hard-link-based snapshots) of a RocksDb database. Maps to rocksdb_checkpoint_t.

ColumnFamilyDescriptor

Descriptor used when opening a database with multiple column families.

ColumnFamilyHandle

A handle to a column family within a RocksDb database. Destroying this handle does not drop the column family from the database.

ColumnFamilyLevelMetadata

Metadata describing the files stored at a single LSM level.

ColumnFamilyMetadata

Metadata describing a column family, including its size and the levels currently stored.

ColumnFamilyMetadataOptions

Narrows what GetColumnFamilyMetadata(ColumnFamilyMetadataOptions) reports, by level and by key range. Maps to rocksdb_column_family_metadata_options_t.

CompactFilesOptions

Options for CompactFiles(CompactFilesOptions?, IReadOnlyList<string>, int, int), which compacts an explicit list of files. Maps to rocksdb_compaction_options_t.

CompactRangeOptions

Options for CompactRange operations.

CompactionCancellationFlag

A flag a running CompactFiles(CompactFilesOptions?, IReadOnlyList<string>, int, int) polls so it can be stopped from another thread. Maps to the rocksdb_compaction_options_canceled_* functions.

CompactionFileInfo

Identifies one input or output file of a compaction. Maps to rocksdb_compaction_file_info_t.

CompactionFilter

User-defined compaction filter. Override Filter(int, ReadOnlySpan<byte>, ReadOnlySpan<byte>, out byte[]?) to inspect or modify key-value pairs during table-file creation (compaction / flush).

CompactionFilterFactory

Creates a fresh CompactionFilter for each compaction / flush job. Preferred over sharing a single filter instance when the filter contains per-compaction state or when thread-safe access to a shared instance is not practical.

CompactionJobInfo

Information about a completed compaction job.

CompactionJobStats

Statistics for a completed compaction job. Maps to rocksdb_compaction_job_stats_t.

Comparator

User-defined comparator for controlling the sort order of keys in a RocksDb database. Override Compare(ReadOnlySpan<byte>, ReadOnlySpan<byte>) to define custom key ordering.

CreateBackupOptions

Options for a single CreateNewBackup(RocksDb, CreateBackupOptions) call. Maps to rocksdb_create_backup_options_t.

DbOptions

Options used when opening a RocksDb instance. Maps to rocksdb_options_t.

DbPath

One directory a database may store data in, with a size target. Maps to rocksdb_dbpath_t.

Env

The environment RocksDb runs against: its background thread pools, and the priorities those threads run at. Maps to rocksdb_env_t.

EnvOptions

Options for configuring the RocksDb environment used by SstFileWriter.

EventListener

Base class for receiving database event notifications such as flushes, compactions, and background errors. Override the virtual methods for events you want to observe.

ExportImportFilesMetadata

Describes an exported column family: the comparator it was written with and the files that make it up. Maps to rocksdb_export_import_files_metadata_t.

ExternalFileIngestionInfo

Information about an external file ingestion event.

FifoCompactionOptions

Tuning for FIFO compaction. Maps to rocksdb_fifo_compaction_options_t.

FileChecksumGenFactory

Produces the whole-file checksums RocksDb records for each SST file it writes. Maps to rocksdb_file_checksum_gen_factory_t.

FilterPolicy

A bloom filter or ribbon filter policy for block-based tables. Maps to rocksdb_filterpolicy_t.

FlushJobInfo

Information about a completed flush job.

FlushOptions

Options for Flush(FlushOptions?) operations.

FlushWalOptions

Options for flushing the write-ahead log. Maps to rocksdb_flushwaloptions_t.

HistogramData

A snapshot of histogram data gathered by RocksDb statistics.

HyperClockCacheOptions

Settings for a HyperClock block cache. Maps to rocksdb_hyper_clock_cache_options_t.

ImportColumnFamilyOptions

How an imported column family's files are taken from the export directory. Maps to rocksdb_import_column_family_options_t.

IngestExternalFileOptions

Options controlling how external SST files are ingested into the database.

Iterator

Iterates over the key-value pairs in a RocksDb database or a single column family. Implements forward and reverse iteration. Maps to rocksdb_iterator_t.

LiveFileMetadata

Metadata for a single live SST file in the database.

LiveFileStorageInfo

One file belonging to a consistent snapshot of the database, described in enough detail to copy it elsewhere. Maps to one entry of rocksdb_livefiles_storage_info_t.

LiveFilesStorageInfoOptions

Options for GetLiveFilesStorageInfo(LiveFilesStorageInfoOptions?). Maps to rocksdb_livefiles_storage_info_options_t.

LoadedOptions

The options a database was last opened with, read back from the OPTIONS- file RocksDb writes into its directory.

Logger

User-defined info logger for RocksDb. Override Log(InfoLogLevel, string) to receive log messages from the database engine.

LruCacheOptions

Settings for a least-recently-used block cache. Maps to rocksdb_lru_cache_options_t.

MemTableInfo

Information about a sealed memtable.

MemoryConsumers

The databases and caches a memory snapshot should cover.

MergeOperator

User-defined merge operator that enables read-modify-write semantics on values stored in RocksDb. Override FullMerge(ReadOnlySpan<byte>, bool, ReadOnlySpan<byte>, IReadOnlyList<byte[]>, out byte[]?) (and optionally PartialMerge(ReadOnlySpan<byte>, IReadOnlyList<byte[]>, out byte[]?)) to implement custom merge logic.

PerfContext

Per-operation profiling counters for the current thread. Maps to rocksdb_perfcontext_t.

PinnableSlice

A value read from the database without copying it into managed memory. Maps to rocksdb_pinnableslice_t.

RateLimiter

Limits the rate of I/O operations (bytes per second). Maps to rocksdb_ratelimiter_t.

ReadOptions

Options that control read operations. Maps to rocksdb_readoptions_t.

RestoreOptions

Options for restoring a database from a backup. Maps to rocksdb_restore_options_t.

RocksDb

A RocksDb embedded key-value database. Thread-safe: all operations may be called concurrently from multiple threads.

RocksDbCallbacks

Process-wide reporting for exceptions that escape managed RocksDb callbacks.

RocksDbException

Represents an error returned by the RocksDb native library.

RocksDbHandle

Abstract base class for all managed wrappers around native RocksDb handles. Provides deterministic disposal via IDisposable and a GC finalizer safety net.

SizeApproximationOptions

Controls what ApproximateSizes(SizeApproximationOptions, IEnumerable<(string Start, string Limit)>) counts when estimating the size of a key range. Maps to rocksdb_size_approximation_options_t.

SliceTransform

A slice transform (prefix extractor) used with prefix bloom filters. Maps to rocksdb_slicetransform_t.

Snapshot

A point-in-time consistent view of the database. Maps to rocksdb_snapshot_t.

SstFileManager

Governs how much disk space a database may use and how fast it may delete files. Maps to rocksdb_sst_file_manager_t.

SstFileMetadata

Metadata for a single SST file.

SstFileWriter

Writes key-value pairs in sorted order to a standalone SST file that can later be ingested into a database via IngestExternalFile(IReadOnlyList<string>, IngestExternalFileOptions). Keys must be added in ascending order.

SstPartitionerFactory

Forces SST file boundaries to fall on key-prefix boundaries. Maps to rocksdb_sst_partitioner_factory_t.

SubCompactionJobInfo

Information about a sub-compaction job.

TableProperties

Properties of a single SST table file, as reported by RocksDb. Maps to rocksdb_table_properties_t.

TablePropertiesView

A read-only window onto an SST file's properties, valid only for the duration of the callback it was handed to.

Transaction

A transaction on a TransactionDb. Maps to rocksdb_transaction_t.

TransactionDb

A database that supports transactions with per-key locking and conflict detection. Maps to rocksdb_transactiondb_t.

TransactionDbOptions

Settings for opening a TransactionDb. Maps to rocksdb_transactiondb_options_t.

TransactionOptions

Settings for a single Transaction. Maps to rocksdb_transaction_options_t.

UniversalCompactionOptions

Tuning for universal compaction. Maps to rocksdb_universal_compaction_options_t.

WaitForCompactOptions

Options for WaitForCompact(WaitForCompactOptions?).

WalFile

Describes one write-ahead log file. Copied from rocksdb_wal_file_t.

WalFilter

Inspects, rewrites or skips write-ahead log records as RocksDb replays them while opening a database. Maps to rocksdb_walfilter_t.

WalIterator

Walks the write-ahead log from a given sequence number, yielding the batches that were written. Maps to rocksdb_wal_iterator_t.

WalReadOptions

Options for reading the write-ahead log through GetUpdatesSince(ulong, WalReadOptions?). Maps to rocksdb_wal_readoptions_t.

WriteBatch

An atomic write batch. Apply to the database with Write(WriteBatch, WriteOptions?). Maps to rocksdb_writebatch_t.

WriteBatchWithIndex

An atomic write batch that also indexes its own contents, so it can be read back before it is applied. Maps to rocksdb_writebatch_wi_t.

WriteBufferManager

A memory budget for memtables, shared across column families and across databases. Maps to rocksdb_write_buffer_manager_t.

WriteOptions

Options that control write operations. Maps to rocksdb_writeoptions_t.

WriteStallInfo

Information about a write stall condition change.

Structs

CompactionFilterContext

Context information passed to CreateFilter(CompactionFilterContext) when RocksDb starts a new compaction or flush job.

Iterator.Entry

One key and value from an Iterator.Enumerator.

Iterator.Enumerator

Walks an iterator without allocating, yielding spans that point straight at the iterator's buffers.

WriteBatchEntry

One operation read back out of a WriteBatch.

Enums

BackgroundErrorReason

What RocksDb was doing when a background error occurred, mapped from rocksdb::BackgroundErrorReason in listener.h.

BlobGarbageCollectionPolicy

Whether a manual compaction should collect blob-file garbage.

BlockBasedTableIndexType

Index type for block-based table.

BottommostLevelCompaction

How a manual compaction should treat the bottommost level, mapped from rocksdb::BottommostLevelCompaction in options.h.

CacheTier

The tiers of cache a read is permitted to reach into.

ChecksumType

Checksum algorithm used to protect each block.

CompactionPri

How RocksDb picks which file to compact next within a level, mapped from rocksdb::CompactionPri in advanced_options.h.

CompactionReason

Why RocksDb ran a compaction, mapped from rocksdb::CompactionReason in listener.h.

CompactionStopStyle

How universal compaction decides where to stop adding files to a compaction, mapped from rocksdb::CompactionStopStyle in universal_compaction.h.

CompactionStyle

Compaction style.

Compression

Compression algorithm used by RocksDb.

CpuPriority

Scheduling priority for the threads that copy files during a backup.

DataBlockIndexType

Index type used inside a data block, which controls how a key is located once its block has been read.

EventKinds

The events an EventListener wants to be told about.

FileType

The kinds of file RocksDb manages inside a database directory.

FilterDecision

Decision returned by a CompactionFilter for each key-value pair encountered during table-file creation (compaction or flush).

FlushReason

Why RocksDb flushed a memtable, mapped from rocksdb::FlushReason in listener.h.

Histogram

A distribution collected by the statistics subsystem.

IndexBlockSearchType

Search algorithm used within an index block.

IndexShortening

How much of the index key RocksDb may discard to save space.

InfoLogLevel

Severity threshold for RocksDb's own informational log. Records below the configured level are not written.

IoActivity

Labels the kind of work an I/O operation belongs to, which RocksDb passes through to the filesystem and to its own statistics.

PerfLevel

How much detail RocksDb collects into the per-thread PerfContext, mapped from rocksdb::PerfLevel in perf_level.h.

PerfMetric

A counter available from a PerfContext, mapped from the metric enumeration in RocksDb's c.h.

PinningTier

Which index and filter blocks are kept pinned in the block cache, mapped from rocksdb::PinningTier in table.h.

PrepopulateBlobCache

Whether newly written blobs are put straight into the blob cache, mapped from rocksdb::PrepopulateBlobCache in advanced_options.h.

PrepopulateBlockCache

Whether newly written blocks are inserted into the block cache before anyone reads them.

RateLimiterPriority

The priority an operation is given by the rate limiter, if one is configured.

ReadTier

Which tiers of storage a read is allowed to reach into.

RestoreMode

How thoroughly a restore replaces the files already in the destination.

StatsLevel

How much RocksDb collects when statistics are enabled, mapped from rocksdb::StatsLevel in statistics.h.

Temperature

A hint about how hot the data in a file is, which lets RocksDb place files on storage suited to how often they are read.

Ticker

A counter collected by the statistics subsystem.

TransactionDbWritePolicy

When a transaction's data reaches the memtable, mapped from rocksdb::TxnDBWritePolicy in utilities/transaction_db.h.

VerifyOutputFlags

Which verifications RocksDb runs over the files a compaction produces, and when.

WalFileType

Whether a WAL file is still being written to or has been archived.

WalProcessingOption

What RocksDb should do with a write-ahead log record during recovery.

WalRecoveryMode

WAL recovery mode.

WriteBatchEntryKind

What kind of operation a WriteBatchEntry records.

WriteStallCondition

The write stall state of a column family, mapped from rocksdb::WriteStallCondition in types.h.

Delegates

Iterator.ForEachDelegate

Receives one key and value during ForEach(ForEachDelegate).