I'm trying to build up a topology (using TopologyBuilder) with following components :
Somehow this does not seem to work.
When creating the topology with exact topic names, all works fine, but it seems not possible to attach state stores when using wildcard topics on the sources.
Inside addStateStore, the processor gets connected to the state store with connectProcessorAndStateStore, and there it will try to connect the state store with the source topics from the processor: connectStateStoreNameToSourceTopics
Here lies the problem:
The call to sourceTopics.addAll(Arrays.asList(((SourceNodeFactory) nodeFactory).getTopics())) will fail as there are no topics inside the SourceNodeFactory object, only a pattern (.getTopics returns null)
I also tried to search for some unit tests inside the Kafka Streams project that cover this scenario, but alas, I was not able to find any.
Only some tests on state stores with exact topic names, and some tests on wildcard topics, but no combination of both ...