THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Code Block |
---|
package org.apache.kafka.streams.internals; public class MockKeyValueStoreBuilder<K, V> extends AbstractStoreBuilder<K, V, StateStore> { final Boolean persistent; public MockKeyValueStoreBuilder(final String storeName, final Serde<K> keySerde, final Serde<V> valueSerde, final Time time, final Boolean persistent) { super(storeName, keySerde, valueSerde, time); this.persistent = persistent; } @Override public KeyValueStore build() { return new MockKeyValueStore(name, persistent); } } |
Then in the Store, we will be a wrapper around a InMemoryStore, and capture all the get/put calls (excluding Iterators)
...