Class InMemorySessionBytesStoreSupplier
- java.lang.Object
-
- org.apache.kafka.streams.state.internals.InMemorySessionBytesStoreSupplier
-
- All Implemented Interfaces:
SessionBytesStoreSupplier,StoreSupplier<SessionStore<org.apache.kafka.common.utils.Bytes,byte[]>>
public class InMemorySessionBytesStoreSupplier extends java.lang.Object implements SessionBytesStoreSupplier
-
-
Constructor Summary
Constructors Constructor Description InMemorySessionBytesStoreSupplier(java.lang.String name, long retentionPeriod)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SessionStore<org.apache.kafka.common.utils.Bytes,byte[]>get()Return a newStateStoreinstance.java.lang.StringmetricsScope()Return a String that is used as the scope for metrics recorded by Metered stores.java.lang.Stringname()Return the name of this state store supplier.longretentionPeriod()The time period for which theSessionStorewill retain historic data.longsegmentIntervalMs()The size of a segment, in milliseconds.
-
-
-
Method Detail
-
name
public java.lang.String name()
Description copied from interface:StoreSupplierReturn the name of this state store supplier. This must be a valid Kafka topic name; valid characters are ASCII alphanumerics, '.', '_' and '-'.- Specified by:
namein interfaceStoreSupplier<SessionStore<org.apache.kafka.common.utils.Bytes,byte[]>>- Returns:
- the name of this state store supplier
-
get
public SessionStore<org.apache.kafka.common.utils.Bytes,byte[]> get()
Description copied from interface:StoreSupplierReturn a newStateStoreinstance.- Specified by:
getin interfaceStoreSupplier<SessionStore<org.apache.kafka.common.utils.Bytes,byte[]>>- Returns:
- a new
StateStoreinstance of type T
-
metricsScope
public java.lang.String metricsScope()
Description copied from interface:StoreSupplierReturn a String that is used as the scope for metrics recorded by Metered stores.- Specified by:
metricsScopein interfaceStoreSupplier<SessionStore<org.apache.kafka.common.utils.Bytes,byte[]>>- Returns:
- metricsScope
-
segmentIntervalMs
public long segmentIntervalMs()
Description copied from interface:SessionBytesStoreSupplierThe size of a segment, in milliseconds. Used when caching is enabled to segment the cache and reduce the amount of data that needs to be scanned when performing range queries.- Specified by:
segmentIntervalMsin interfaceSessionBytesStoreSupplier- Returns:
- segmentInterval in milliseconds
-
retentionPeriod
public long retentionPeriod()
Description copied from interface:SessionBytesStoreSupplierThe time period for which theSessionStorewill retain historic data.- Specified by:
retentionPeriodin interfaceSessionBytesStoreSupplier- Returns:
- retentionPeriod
-
-