case class CompositeTable[F[_], P, S](tableName: String, partitionKeyDef: KeyDef[P], sortKeyDef: KeyDef[S], jClient: DynamoDbAsyncClient)(implicit evidence$9: Async[F], evidence$10: Encoder[P], evidence$11: Encoder[S]) extends CompositeIndex[F, P, S] with PutOps with CompositeKeysDeleteOps with CompositeKeysUpdateOps with CompositeKeysBatchGetOps with CompositeKeysBatchWriteOps with Product with Serializable
Represent a table where the index is composite keys (partition key and sort key).
- P
partition key's type
- S
sort key's type
- tableName
table's name
- partitionKeyDef
partition key definition
- sortKeyDef
sort key definition
- jClient
DynamoDB java async client
- Alphabetic
- By Inheritance
- CompositeTable
- Serializable
- Product
- Equals
- CompositeKeysBatchWriteOps
- SharedBatchWriteOps
- CompositeKeysBatchGetOps
- SharedBatchGetOps
- DedupOps
- CompositeKeysUpdateOps
- SharedUpdateOps
- CompositeKeysDeleteOps
- PutOps
- CompositeIndex
- CompositeKeysGetOps
- SharedGetOps
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new CompositeTable(tableName: String, partitionKeyDef: KeyDef[P], sortKeyDef: KeyDef[S], jClient: DynamoDbAsyncClient)(implicit arg0: Async[F], arg1: Encoder[P], arg2: Encoder[S])
- tableName
table's name
- partitionKeyDef
partition key definition
- sortKeyDef
sort key definition
- jClient
DynamoDB java async client
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def batchDelete(maxBatchWait: FiniteDuration, parallelism: Int, backoffStrategy: BackoffStrategy): Pipe[F, (P, S), Unit]
Delete items by composite keys in batch.
Delete items by composite keys in batch. Max batch size is preset to 100 (maximum batch size permitted for batch get action), however, it is possible to control the rate of batching with
maxBatchWait
parameter. This uses fs2 .groupWithin internally. This returns a Pipe in order to cover broader use cases regardless of input can be fitted into memory or not. Duplicated items within a batch will be removed. Left over items within a batch will be reprocessed in the next batch.- maxBatchWait
time window to collect items into a batch
- parallelism
number of connections that can be open at the same time
- backoffStrategy
backoff strategy in case of failure, default can be found at meteor.Client.BackoffStrategy.default.
- returns
a fs2 Pipe from composite keys P and S as a tuple to Unit
- def batchGet[T](consistentRead: Boolean, projection: Expression, maxBatchWait: FiniteDuration, parallelism: Int, backoffStrategy: BackoffStrategy)(implicit arg0: Decoder[T]): Pipe[F, (P, S), T]
Get items by composite keys in batch.
Get items by composite keys in batch. Max batch size is preset to 100 (maximum batch size permitted for batch get action), however, it is possible to control the rate of batching with
maxBatchWait
parameter. This uses fs2 .groupWithin internally. This returns a Pipe in order to cover broader use cases regardless of input can be fitted into memory or not. Duplicated items within a batch will be removed. Left over items within a batch will be reprocessed in the next batch.- T
returned item's type
- consistentRead
flag to enable strongly consistent read
- projection
projection expression
- maxBatchWait
time window to collect items into a batch
- parallelism
number of connections that can be open at the same time
- backoffStrategy
backoff strategy in case of failure, default can be found at meteor.Client.BackoffStrategy.default.
- returns
a fs2 Pipe from composite keys P and S as a tuple to T
- def batchPut[T](maxBatchWait: FiniteDuration, backoffStrategy: BackoffStrategy)(implicit arg0: Encoder[T]): Pipe[F, T, Unit]
Put items in batch, in ordered.
Put items in batch, in ordered. Meaning batches are processed in serial to avoid race condition when writing items with the same composite keys. If your input doesn't have this constrain, you can use batchPutUnordered. Max batch size is preset to 25 (maximum batch size permitted from batch put actions), however, it is possible to control the rate of batching with
maxBatchWait
parameter. This uses fs2 .groupWithin internally. This returns a Pipe in order to cover broader use cases regardless of input can be fitted into memory or not. Duplicated items within a batch will be removed. Left over items within a batch will be reprocessed in the next batch.- T
returned item's type
- maxBatchWait
time window to collect items into a batch
- backoffStrategy
backoff strategy in case of failure, default can be found at meteor.Client.BackoffStrategy.default.
- returns
a fs2 Pipe from T to Unit
- def batchPutUnordered[T](maxBatchWait: FiniteDuration, parallelism: Int, backoffStrategy: BackoffStrategy)(implicit arg0: Encoder[T]): Pipe[F, T, Unit]
Put items in batch, un-ordered.
Put items in batch, un-ordered. Meaning batches are processed in parallel, hence, if your input has items with the same composite keys, this can cause a race condition, consider using batchPut instead. Max batch size is preset to 25 (maximum batch size permitted from batch put actions), however, it is possible to control the rate of batching with
maxBatchWait
parameter. This uses fs2 .groupWithin internally. This returns a Pipe in order to cover broader use cases regardless of input can be fitted into memory or not. Duplicated items within a batch will be removed. Left over items within a batch will be reprocessed in the next batch.- T
returned item's type
- maxBatchWait
time window to collect items into a batch
- parallelism
number of connections that can be open at the same time
- backoffStrategy
backoff strategy in case of failure, default can be found at meteor.Client.BackoffStrategy.default.
- returns
a fs2 Pipe from T to Unit
- def batchWrite[T](maxBatchWait: FiniteDuration, backoffStrategy: BackoffStrategy)(implicit arg0: Encoder[T]): Pipe[F, Either[(P, S), T], Unit]
Write items (put or delete) in batch, in ordered.
Write items (put or delete) in batch, in ordered. Meaning batches are processed in serial to avoid race condition when writing items with the same composite keys. Max batch size is preset to 25 (maximum batch size permitted from batch write actions), however, it is possible to control the rate of batching with
maxBatchWait
parameter. This uses fs2 .groupWithin internally. This returns a Pipe in order to cover broader use cases regardless of input can be fitted into memory or not. Duplicated items within a batch will be removed. Left over items within a batch will be reprocessed in the next batch.- T
returned item's type
- maxBatchWait
time window to collect items into a batch
- backoffStrategy
backoff strategy in case of failure, default can be found at meteor.Client.BackoffStrategy.default.
- returns
a fs2 Pipe from Either[(P, S), T], represent deletion (Left) or put (Right) to Unit.
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
- def delete(partitionKey: P, sortKey: S): F[Unit]
Delete an item by composite keys.
Delete an item by composite keys.
- partitionKey
partition key
- sortKey
sort key
- returns
Unit
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def get[T](partitionKey: P, sortKey: S, consistentRead: Boolean)(implicit arg0: Decoder[T]): F[Option[T]]
Get a single item by composite keys.
Get a single item by composite keys.
- T
returned item's type
- partitionKey
partition key
- sortKey
sort key
- consistentRead
flag to enable strongly consistent read
- returns
an optional item of type T
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- val index: CompositeKeysIndex[P, S]
- Definition Classes
- CompositeTable → CompositeIndex
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val jClient: DynamoDbAsyncClient
- Definition Classes
- CompositeTable → CompositeIndex
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- val partitionKeyDef: KeyDef[P]
- Definition Classes
- CompositeTable → CompositeIndex
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- def put[T, U](t: T, condition: Expression)(implicit arg0: Encoder[T], arg1: Decoder[U]): F[Option[U]]
Put an item into a table and return previous value.
Put an item into a table and return previous value.
- T
item's type
- U
returned item's type
- t
item to be put
- condition
conditional expression
- returns
an option item of type U
- def put[T](t: T, condition: Expression = Expression.empty)(implicit arg0: Encoder[T]): F[Unit]
Put an item into a table.
Put an item into a table.
- T
item's type
- t
item to be put
- condition
conditional expression
- returns
Unit
- def retrieve[T](partitionKey: P, consistentRead: Boolean, limit: Int)(implicit arg0: Decoder[T], RT: RaiseThrowable[F]): Stream[F, T]
Retrieve all items with the same partition key as a fs2 Stream.
Retrieve all items with the same partition key as a fs2 Stream. The number of returned items can be limited. A Stream is returned instead of a list because the number of returned items can be very large.
- T
returned item's type
- partitionKey
partition key
- consistentRead
flag to enable strongly consistent read
- limit
number of items to be returned
- RT
implicit evidence for RaiseThrowable
- returns
a fs2 Stream of items
- def retrieve[T](query: Query[P, S], consistentRead: Boolean, limit: Int)(implicit arg0: Decoder[T], RT: RaiseThrowable[F]): Stream[F, T]
Retrieve items from a composite index, can be a secondary index or a table which has composite keys (partition key and sort key).
Retrieve items from a composite index, can be a secondary index or a table which has composite keys (partition key and sort key).
- T
return item's type
- query
a query to filter items by key condition
- consistentRead
toggle to perform consistent read
- limit
limit the number of items to be returned
- RT
implicit evidence for RaiseThrowable
- returns
a fs2 Stream of items
- Definition Classes
- CompositeIndex
- val sortKeyDef: KeyDef[S]
- Definition Classes
- CompositeTable → CompositeIndex
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- val tableName: String
- def update[T](partitionKey: P, sortKey: S, returnValue: ReturnValue, update: Expression, condition: Expression)(implicit arg0: Decoder[T]): F[Option[T]]
Update an item by composite keys given an update expression when a condition expression is fulfilled.
Update an item by composite keys given an update expression when a condition expression is fulfilled. Return item is customizable via
returnValue
parameter.- T
returned item's type
- partitionKey
partition key
- sortKey
sort key
- returnValue
flag to define which item to be returned
- update
update expression
- condition
conditional expression
- returns
an optional item of type T
- def update(partitionKey: P, sortKey: S, update: Expression, condition: Expression = Expression.empty): F[Unit]
Update an item by composite keys given an update expression when a condition expression is fulfilled.
Update an item by composite keys given an update expression when a condition expression is fulfilled. Return Unit.
- partitionKey
partition key
- sortKey
sort key
- update
update expression
- condition
conditional expression
- returns
Unit
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated