camel-quarkus icon indicating copy to clipboard operation
camel-quarkus copied to clipboard

Improve automatic reload on Camel route

Open apupier opened this issue 2 months ago • 3 comments

Describe the feature here

reloading a relatively simple Camel route is taking 6 seconds (on my machine).

a log is suggesting some ways to have small changes ot be faster (like in my case changing the content of a string in a log message):

2025-11-07 18:02:58,992 INFO  [io.qua.dep.dev.RuntimeUpdatesProcessor] (Timer-0) Live reload took more than 4 seconds, you may want to enable instrumentation based reload (quarkus.live-reload.instrumentation=true). This allows small changes to take effect without restarting Quarkus.

(and yes I realize that there can be a lot of different use cases and a lot of work but maybe some quick win available?)

apupier avatar Nov 07 '25 17:11 apupier

Reloading a relatively simple Camel route is taking 6 seconds

Can you share a reproducer?

jamesnetherton avatar Nov 11 '25 12:11 jamesnetherton

camel-quarkus reproducer.zip

  • start with mvn quarkus:dev
  • after the route is running, changing the string in the setBody().simple

apupier avatar Nov 11 '25 17:11 apupier

Ok - so in this case it's extra time taken for graceful shutdown of the Kafka consumer / producer.

You can speed it up a bit with:

%dev.camel.component.kafka.shutdown-timeout=1000

We could perhaps force this config automatically in dev mode. Not sure how safe it is though. I noticed if you set smaller timeout values then you get some ugly InterruptedException messages in the console logs.

jamesnetherton avatar Nov 12 '25 07:11 jamesnetherton