← ZIO Rocksdb docs

RocksDB

zio.rocksdb.RocksDB
See theRocksDB companion object
trait RocksDB

Attributes

Companion
object
Source
RocksDB.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Live

Members list

Value members

Abstract methods

def createColumnFamilies(columnFamilyDescriptors: List[ColumnFamilyDescriptor]): Task[List[ColumnFamilyHandle]]

Creates ColumnFamilies from a list of ColumnFamilyDescriptors

Creates ColumnFamilies from a list of ColumnFamilyDescriptors

Attributes

Source
RocksDB.scala
def createColumnFamilies(columnFamilyOptions: ColumnFamilyOptions, columnFamilyNames: List[Array[Byte]]): Task[List[ColumnFamilyHandle]]

Creates ColumnFamilies from a list of ColumnFamilyNames and ColumnFamilyOptions

Creates ColumnFamilies from a list of ColumnFamilyNames and ColumnFamilyOptions

Attributes

Source
RocksDB.scala
def createColumnFamily(columnFamilyDescriptor: ColumnFamilyDescriptor): Task[ColumnFamilyHandle]

Creates a new ColumnFamily from ColumnFamilyDescriptor

Creates a new ColumnFamily from ColumnFamilyDescriptor

Attributes

Source
RocksDB.scala
def delete(key: Array[Byte]): Task[Unit]

Delete a key from the default ColumnFamily in the database.

Delete a key from the default ColumnFamily in the database.

Attributes

Source
RocksDB.scala
def delete(cfHandle: ColumnFamilyHandle, key: Array[Byte]): Task[Unit]

Delete a key from a specific ColumnFamily in the database.

Delete a key from a specific ColumnFamily in the database.

Attributes

Source
RocksDB.scala
def dropColumnFamilies(columnFamilyHandles: List[ColumnFamilyHandle]): Task[Unit]

Deletes ColumnFamilies given a list of ColumnFamilyHandles

Deletes ColumnFamilies given a list of ColumnFamilyHandles

Attributes

Source
RocksDB.scala
def dropColumnFamily(columnFamilyHandle: ColumnFamilyHandle): Task[Unit]

Deletes a ColumnFamily

Deletes a ColumnFamily

Attributes

Source
RocksDB.scala
def flush(flushOptions: FlushOptions): Task[Unit]

Flush all memory table data

Flush all memory table data

Attributes

Source
RocksDB.scala
def flush(flushOptions: FlushOptions, columnFamilyHandle: ColumnFamilyHandle): Task[Unit]

Flush all memory table data.

Flush all memory table data.

Attributes

Source
RocksDB.scala
def flush(flushOptions: FlushOptions, columnFamilyHandles: List[ColumnFamilyHandle]): Task[Unit]

Flush multiple column families.

Flush multiple column families.

Attributes

Source
RocksDB.scala
def flushWal(sync: Boolean): Task[Unit]

Flush the WAL memory buffer to the file

Flush the WAL memory buffer to the file

Attributes

Source
RocksDB.scala
def get(key: Array[Byte]): Task[Option[Array[Byte]]]

Retrieve a key from the default ColumnFamily in the database.

Retrieve a key from the default ColumnFamily in the database.

Attributes

Source
RocksDB.scala
def get(cfHandle: ColumnFamilyHandle, key: Array[Byte]): Task[Option[Array[Byte]]]

Retrieve a key from a specific ColumnFamily in the database.

Retrieve a key from a specific ColumnFamily in the database.

Attributes

Source
RocksDB.scala
def initialHandles: Task[List[ColumnFamilyHandle]]

Retrieves the list of ColumnFamily handles the database was opened with.

Retrieves the list of ColumnFamily handles the database was opened with.

Caveats:

  • This list will only be populated if the database was opened with a specific list of column families.
  • The list will not be updated if column families are added/removed while the database is open.

Attributes

Source
RocksDB.scala

Retrieve multiple keys from the default ColumnFamily in the database. The resulting list corresponds (positionally) to the list of keys passed to the function.

Retrieve multiple keys from the default ColumnFamily in the database. The resulting list corresponds (positionally) to the list of keys passed to the function.

Attributes

Source
RocksDB.scala
def multiGetAsList(handles: List[ColumnFamilyHandle], keys: List[Array[Byte]]): Task[List[Option[Array[Byte]]]]

Retrieve multiple keys from specific ColumnFamilies in the database. The resulting list corresponds (positionally) to the list of keys passed to the function.

Retrieve multiple keys from specific ColumnFamilies in the database. The resulting list corresponds (positionally) to the list of keys passed to the function.

Attributes

Source
RocksDB.scala

Scans the default ColumnFamily in the database and emits the results as a ZStream.

Scans the default ColumnFamily in the database and emits the results as a ZStream.

Attributes

Source
RocksDB.scala
def newIterator(direction: Direction, position: Position): Stream[Throwable, (Array[Byte], Array[Byte])]

Scans the default ColumnFamily in the database and emits the results as a ZStream.

Scans the default ColumnFamily in the database and emits the results as a ZStream.

Attributes

Source
RocksDB.scala
def newIterator(cfHandle: ColumnFamilyHandle): Stream[Throwable, (Array[Byte], Array[Byte])]

Scans a specific ColumnFamily in the database and emits the results as a ZStream.

Scans a specific ColumnFamily in the database and emits the results as a ZStream.

Attributes

Source
RocksDB.scala
def newIterator(cfHandle: ColumnFamilyHandle, direction: Direction, position: Position): Stream[Throwable, (Array[Byte], Array[Byte])]

Scans a specific ColumnFamily in the database by specifying direction and position and emits the results as a ZStream.

Scans a specific ColumnFamily in the database by specifying direction and position and emits the results as a ZStream.

Attributes

Source
RocksDB.scala
def newIterators(cfHandles: List[ColumnFamilyHandle]): Stream[Throwable, (ColumnFamilyHandle, Stream[Throwable, (Array[Byte], Array[Byte])])]

Scans multiple ColumnFamilies in the database and emits the results in multiple streams, whereas the streams themselves are also emitted in a ZStream.

Scans multiple ColumnFamilies in the database and emits the results in multiple streams, whereas the streams themselves are also emitted in a ZStream.

Attributes

Source
RocksDB.scala
def put(key: Array[Byte], value: Array[Byte]): Task[Unit]

Writes a key to the default ColumnFamily in the database.

Writes a key to the default ColumnFamily in the database.

Attributes

Source
RocksDB.scala
def put(cfHandle: ColumnFamilyHandle, key: Array[Byte], value: Array[Byte]): Task[Unit]

Writes a key to a specific ColumnFamily in the database.

Writes a key to a specific ColumnFamily in the database.

Attributes

Source
RocksDB.scala
def write(writeOptions: WriteOptions, writeBatch: WriteBatch): Task[Unit]

Attributes

Source
RocksDB.scala