Closed yoniwg closed 6 months ago
@yoniwg I believe this a duplicate of https://github.com/spring-projects/spring-kafka/issues/3176. This has been addressed recently.
Closing the issue. Feel free to reopen it if you still see issues with the applied fix on https://github.com/spring-projects/spring-kafka/issues/3176.
In what version(s) of Spring for Apache Kafka are you seeing this issue?
For example:
3.0.10
Describe the bug
The configuration set via
KafkaStreamsConfiguration
bean are not passed into theStreamBuilder
instance, hence, ignored during the build of the topology. Specifically, I am trying to setdefault.dsl.store=in_memory
, but when I useMaterialized.as("Store-Name")
it creates theMetrializedInternal
(Which is used during the topology build process) object (Which is used during the topology build process) withstoreType=ROCKS_DB
. The code that defines the store type inMaterializedInternal
is:So it is capable of taking the configuration from the
InternalStreamsBuilder
. But whenStreamsBuilderFactoryBean
creates theStreamBuilder
here:it does not use the constructor
StreamsBuilder(TopologyConfig)
which enables to pass the topology config, which in turn, used to create theInternalStreamsBuilder
To Reproduce
Materialized
(for example:KTable<K, V>.filter(Predicate<? super K, ? super V> ,Materialized<K, V, KeyValueStore<Bytes, byte[]>>)
)state.dir
folder) and find out rocksdb is still in use.Expected behavior
After passing
kafkaProperties.put(StreamsConfig.DEFAULT_DSL_STORE_CONFIG, StreamsConfig.IN_MEMORY)
, all DSL state-stores must be ofIN_MEMORY
type even when usingMaterialized
(unless configured explicitly else via theMaterialized
object)