Open fedinskiy opened 1 week ago
/cc @alesj (kafka,kafka-streams), @cescoffier (kafka), @gunnarmorling (kafka-streams), @ozangunalp (kafka,kafka-streams), @rquinio (kafka-streams)
@fedinskiy You need to produce a bean of type org.apache.kafka.streams.Topology, for instance https://github.com/quarkusio/quarkus-quickstarts/blob/4741f553ce3f2b3ee8549816a7cba4eca0931f68/kafka-streams-quickstart/aggregator/src/main/java/org/acme/kafka/streams/aggregator/streams/TopologyProducer.java#L33
There's the extension https://github.com/quarkiverse/quarkus-kafka-streams-processor that will automatically produce a Topology based on configuration, but it's limited to simple Processors.
@rquinio thank you for your advice! Is it possible to have this as a dev mode error instead of UnsatisfiedResolutionException? Also:
Describe the bug
I have an application, which contains kafka-streams dependency. When I start the application in a dev mode, it fails with UnsatisfiedResolutionException in Quarkus code.
Expected behavior
Application shouldn't fail, or should tell user, that must be fixed in the application/configs/environment.
Actual behavior
How to Reproduce?
wget -O app.zip 'https://code.quarkus.io/d?e=rest&e=kafka-streams&e=messaging-kafka&cn=code.quarkus.io'
unzip -q app.zip && cd code-with-quarkus/
mvn quarkus:dev
If the app is built and run in prod mode, it starts without any problem:
mvn clean install && java -jar target/quarkus-app/quarkus-run.jar
If the kafka-streams is removed, the app works in dev mode as well:quarkus extension remove kafka-streams
mvn quarkus:dev
Output of
uname -a
orver
6.7.3-200.fc39.x86_64
Output of
java -version
Java version: 21.0.1, vendor: Eclipse Adoptium
Quarkus version or git rev
3.11.3
Build tool (ie. output of
mvnw --version
orgradlew --version
)Apache Maven 3.9.6 (bc0240f3c744dd6b6ec2920b3cd08dcc295161ae)
Additional information
No response