K
- the type of keysV
- the type of valuespublic static interface Stores.InMemoryKeyValueFactory<K,V>
Modifier and Type | Method and Description |
---|---|
StateStoreSupplier |
build()
Return the instance of StateStoreSupplier of new key-value store.
|
Stores.InMemoryKeyValueFactory<K,V> |
maxEntries(int capacity)
Limits the in-memory key-value store to hold a maximum number of entries.
|
Stores.InMemoryKeyValueFactory<K,V> maxEntries(int capacity)
Integer.MAX_VALUE
, which is
equivalent to not placing a limit on the number of entries.capacity
- the maximum capacity of the in-memory cache; should be one less than a power of 2IllegalArgumentException
- if the capacity is not positiveStateStoreSupplier build()