Struct solana_ledger::blockstore_db::Rocks
source · struct Rocks {
db: DB,
access_type: AccessType,
oldest_slot: OldestSlot,
column_options: LedgerColumnOptions,
write_batch_perf_status: PerfSamplingStatus,
}
Fields§
§db: DB
§access_type: AccessType
§oldest_slot: OldestSlot
§column_options: LedgerColumnOptions
§write_batch_perf_status: PerfSamplingStatus
Implementations§
source§impl Rocks
impl Rocks
fn open(path: &Path, options: BlockstoreOptions) -> Result<Rocks>
fn cf_descriptors( options: &BlockstoreOptions, oldest_slot: &OldestSlot ) -> Vec<ColumnFamilyDescriptor>
fn columns() -> Vec<&'static str>
fn destroy(path: &Path) -> Result<()>
fn cf_handle(&self, cf: &str) -> &ColumnFamily
fn get_cf(&self, cf: &ColumnFamily, key: &[u8]) -> Result<Option<Vec<u8>>>
fn get_pinned_cf( &self, cf: &ColumnFamily, key: &[u8] ) -> Result<Option<DBPinnableSlice<'_>>>
fn put_cf(&self, cf: &ColumnFamily, key: &[u8], value: &[u8]) -> Result<()>
fn multi_get_cf( &self, cf: &ColumnFamily, keys: Vec<&[u8]> ) -> Vec<Result<Option<DBPinnableSlice<'_>>>>
fn delete_cf(&self, cf: &ColumnFamily, key: &[u8]) -> Result<()>
sourcefn delete_file_in_range_cf(
&self,
cf: &ColumnFamily,
from_key: &[u8],
to_key: &[u8]
) -> Result<()>
fn delete_file_in_range_cf( &self, cf: &ColumnFamily, from_key: &[u8], to_key: &[u8] ) -> Result<()>
Delete files whose slot range is within [from
, to
].
fn iterator_cf<C>( &self, cf: &ColumnFamily, iterator_mode: IteratorMode<C::Index> ) -> DBIterator<'_>where C: Column,
fn raw_iterator_cf(&self, cf: &ColumnFamily) -> DBRawIterator<'_>
fn batch(&self) -> RWriteBatch
fn write(&self, batch: RWriteBatch) -> Result<()>
fn is_primary_access(&self) -> bool
sourcefn get_int_property_cf(
&self,
cf: &ColumnFamily,
name: &'static CStr
) -> Result<i64>
fn get_int_property_cf( &self, cf: &ColumnFamily, name: &'static CStr ) -> Result<i64>
Retrieves the specified RocksDB integer property of the current column family.
Full list of properties that return int values could be found here.
fn live_files_metadata(&self) -> Result<Vec<LiveFile>>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Rocks
impl Send for Rocks
impl Sync for Rocks
impl Unpin for Rocks
impl UnwindSafe for Rocks
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request