NCBI C++ ToolKit
Public Attributes | List of all members
MDB_meta Struct Reference

Search Toolkit Book for MDB_meta

Meta page content. More...

+ Collaboration diagram for MDB_meta:

Public Attributes

uint32_t mm_magic
 Stamp identifying this as an LMDB file. More...
 
uint32_t mm_version
 Version number of this file. More...
 
void * mm_address
 address for fixed mapping More...
 
size_t mm_mapsize
 size of mmap region More...
 
MDB_db mm_dbs [2]
 first is free space, 2nd is main db More...
 
pgno_t mm_last_pg
 Last used page in the datafile. More...
 
volatile txnid_t mm_txnid
 txnid that committed this page More...
 

Detailed Description

Meta page content.

A meta page is the start point for accessing a database snapshot. Pages 0-1 are meta pages. Transaction N writes meta page #(N % 2).

Definition at line 1036 of file mdb.c.

Member Data Documentation

◆ mm_address

void* MDB_meta::mm_address

address for fixed mapping

Definition at line 1042 of file mdb.c.

Referenced by mdb_env_copyfd1(), mdb_env_info(), and mdb_env_open2().

◆ mm_dbs

MDB_db MDB_meta::mm_dbs[2]

first is free space, 2nd is main db

Definition at line 1044 of file mdb.c.

Referenced by mdb_env_copyfd1(), mdb_env_init_meta0(), mdb_env_open2(), mdb_env_stat(), mdb_env_write_meta(), and mdb_txn_renew0().

◆ mm_last_pg

pgno_t MDB_meta::mm_last_pg

Last used page in the datafile.

Actually the file may be shorter if the freeDB lists the final pages.

Definition at line 1052 of file mdb.c.

Referenced by mdb_env_copyfd1(), mdb_env_info(), mdb_env_init_meta0(), mdb_env_open2(), mdb_env_set_mapsize(), mdb_env_write_meta(), and mdb_txn_renew0().

◆ mm_magic

uint32_t MDB_meta::mm_magic

Stamp identifying this as an LMDB file.

It must be set to MDB_MAGIC.

Definition at line 1039 of file mdb.c.

Referenced by mdb_env_init_meta0(), and mdb_env_read_header().

◆ mm_mapsize

size_t MDB_meta::mm_mapsize

size of mmap region

Definition at line 1043 of file mdb.c.

Referenced by mdb_env_init_meta0(), mdb_env_open2(), mdb_env_set_mapsize(), and mdb_env_write_meta().

◆ mm_txnid

volatile txnid_t MDB_meta::mm_txnid

◆ mm_version

uint32_t MDB_meta::mm_version

Version number of this file.

Must be set to MDB_DATA_VERSION.

Definition at line 1041 of file mdb.c.

Referenced by mdb_env_init_meta0(), mdb_env_open2(), and mdb_env_read_header().


The documentation for this struct was generated from the following file:
Modified on Fri Jan 05 07:21:51 2024 by modify_doxy.py rev. 669887