PravegaTable

zio.pravega.PravegaTable
See thePravegaTable companion trait
object PravegaTable

Pravega Table API companion object with accessible methods.

Attributes

Companion
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def fromScope(scope: String): ZLayer[Scope & ClientConfig, Throwable, PravegaTable]

Create a PravegaTable layer from a scope name and a client config found in the environment.

Create a PravegaTable layer from a scope name and a client config found in the environment.

Attributes

def fromScope(scope: String, clientConfig: ClientConfig): ZLayer[Scope, Throwable, PravegaTable]

Create a PravegaTable layer from a scope name and a client config.

Create a PravegaTable layer from a scope name and a client config.

Attributes

def get[K, V](tableName: String, key: K, settings: TableReaderSettings[K, V]): ZIO[PravegaTable, Throwable, Option[V]]

Get a value from a Pravega table.

Get a value from a Pravega table.

Attributes

def merge[K, V](tableName: String, key: K, value: V, combine: (V, V) => V, settings: TableWriterSettings[K, V]): ZIO[PravegaTable, Throwable, V]
def openTable[K, V](tableName: String, tableSetting: TableSettings[K, V]): ZIO[Scope & PravegaTable, Throwable, PravegaKeyValueTable[K, V]]
def put[K, V](tableName: String, key: K, value: V, settings: TableWriterSettings[K, V]): ZIO[PravegaTable, Throwable, Unit]

Insert a value in a Pravega table, may overwrite existing values.

Insert a value in a Pravega table, may overwrite existing values.

In case of a conflict, the ZIO will fail and will be retried.

Attributes

def readerFlow[K, V](tableName: String, settings: TableReaderSettings[K, V]): ZPipeline[PravegaTable, Throwable, K, Option[TableEntry[V]]]

Create a reader flow, which reads from a KVP Pravega table.

Create a reader flow, which reads from a KVP Pravega table.

The reader flow emits an optional value, which is None if the key is not found.

Attributes

def sink[K, V](tableName: String, settings: TableWriterSettings[K, V], combine: (V, V) => V): ZSink[PravegaTable, Throwable, (K, V), Nothing, Unit]
def source[K, V](tableName: String, settings: TableReaderSettings[K, V]): ZStream[PravegaTable, Throwable, TableEntry[V]]

Create a reader source, which reads from a KVP Pravega table.

Create a reader source, which reads from a KVP Pravega table.

Read entries are emitted in chunks.

Attributes

def writerFlow[K, V](tableName: String, settings: TableWriterSettings[K, V], combine: (V, V) => V): ZPipeline[PravegaTable, Throwable, (K, V), (K, V)]

Create a writer flow to a KVP Pravega table.

Create a writer flow to a KVP Pravega table.

A @combine function is used to merge old and new entries, and new values are emitted.

Attributes