Skip to content

Latest commit

 

History

History
143 lines (94 loc) · 3.94 KB

kafka-streams-StateStore.adoc

File metadata and controls

143 lines (94 loc) · 3.94 KB

StateStore Contract — State Storage Engines

StateStore is the contract of state storage engines (state stores) that store a state.

StateStore can be persistent or not (i.e. in-memory).

Table 1. StateStore Contract
Method Description

close

void close()

Closes the state store

Used when:

flush

void flush()

Flushes cached data

Used when:

init

void init(
  ProcessorContext context,
  StateStore root)

Initializes the state store

Used when:

isOpen

boolean isOpen()

Indicates whether the state store is open or not

Used when:

name

String name()

Name of the state store (for identification purposes)

persistent

boolean persistent()

Indicates whether the state store is persistent (true) or not (false)

Used when:

Table 2. StateStores (Direct Extensions)
StateStore Description

KeyValueStore

SegmentedBytesStore

SessionStore

TimeOrderedKeyValueBuffer

WindowStore

WrappedStateStore