You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "squakez (via GitHub)" <gi...@apache.org> on 2023/04/24 15:00:10 UTC

[GitHub] [camel-k] squakez commented on issue #4192: Startup times take way longer than advertised numbers

squakez commented on issue #4192:
URL: https://github.com/apache/camel-k/issues/4192#issuecomment-1520344271

   I am testing this locally and I cannot see any deviation from what we expect when we run it in JVM mode:
   ```
   [2] 2023-04-24 14:41:25,734 INFO  [org.apa.cam.k.Runtime] (main) Apache Camel K Runtime 1.17.0
   [2] 2023-04-24 14:41:25,753 INFO  [org.apa.cam.qua.cor.CamelBootstrapRecorder] (main) Bootstrap runtime: org.apache.camel.quarkus.main.CamelMainRuntime
   [2] 2023-04-24 14:41:25,756 INFO  [org.apa.cam.mai.MainSupport] (main) Apache Camel (Main) 3.20.1 is starting
   [2] 2023-04-24 14:41:25,798 INFO  [org.apa.cam.k.lis.SourcesConfigurer] (main) Loading routes from: SourceDefinition{name='TestOne', language='java', type='source', location='file:/etc/camel/sources/TestOne.java', }
   [2] 2023-04-24 14:41:26,698 INFO  [org.apa.cam.k.lis.SourcesConfigurer] (main) Loading routes from: SourceDefinition{name='test-one-openapi', language='xml', type='source', location='file:/etc/camel/sources/test-one-openapi.xml', }
   [2] 2023-04-24 14:41:27,006 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Apache Camel 3.20.1 (camel-1) is starting
   [2] 2023-04-24 14:41:27,023 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Routes startup (started:4)
   [2] 2023-04-24 14:41:27,023 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started mertGet (direct://mertGet)
   [2] 2023-04-24 14:41:27,023 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started mertPost (direct://mertPost)
   [2] 2023-04-24 14:41:27,024 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started route1 (rest://get:/mert)
   [2] 2023-04-24 14:41:27,024 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started route2 (rest://post:/mert)
   [2] 2023-04-24 14:41:27,024 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Apache Camel 3.20.1 (camel-1) started in 140ms (build:0ms init:123ms start:17ms)
   [2] 2023-04-24 14:41:27,117 INFO  [io.quarkus] (main) camel-k-integration 1.12.0 on JVM (powered by Quarkus 2.16.0.Final) started in 3.159s. Listening on: http://0.0.0.0:8080
   [2] 2023-04-24 14:41:27,118 INFO  [io.quarkus] (main) Profile prod activated. 
   [2] 2023-04-24 14:41:27,118 INFO  [io.quarkus] (main) Installed features: [camel-attachments, camel-bean, camel-core, camel-direct, camel-java-joor-dsl, camel-k-core, camel-k-runtime, camel-kubernetes, camel-platform-http, camel-rest, camel-xml-io-dsl, cdi, kubernetes-client, security, smallrye-context-propagation, vertx]
   ```
   However, something strange happens when I am running in native mode (which is what you may be experiencing):
   ```
   [2] 2023-04-24 14:43:36,452 INFO  [org.apa.cam.k.Runtime] (main) Apache Camel K Runtime 1.17.0
   [2] 2023-04-24 14:43:36,966 INFO  [org.apa.cam.qua.cor.CamelBootstrapRecorder] (main) Bootstrap runtime: org.apache.camel.quarkus.main.CamelMainRuntime
   [2] 2023-04-24 14:43:37,056 INFO  [org.apa.cam.mai.MainSupport] (main) Apache Camel (Main) 3.20.1 is starting
   [2] 2023-04-24 14:43:37,356 INFO  [org.apa.cam.k.lis.SourcesConfigurer] (main) Loading routes from: SourceDefinition{name='TestOne', language='java', type='source', location='file:/etc/camel/sources/TestOne.java', }
   [2] 2023-04-24 14:43:50,771 INFO  [org.apa.cam.k.lis.SourcesConfigurer] (main) Loading routes from: SourceDefinition{name='test-one-openapi', language='xml', type='source', location='file:/etc/camel/sources/test-one-openapi.xml', }
   [2] 2023-04-24 14:43:53,956 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Apache Camel 3.20.1 (camel-1) is starting
   [2] 2023-04-24 14:43:54,052 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Routes startup (started:4)
   [2] 2023-04-24 14:43:54,053 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started mertGet (direct://mertGet)
   [2] 2023-04-24 14:43:54,053 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started mertPost (direct://mertPost)
   [2] 2023-04-24 14:43:54,054 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started route1 (rest://get:/mert)
   [2] 2023-04-24 14:43:54,055 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started route2 (rest://post:/mert)
   [2] 2023-04-24 14:43:54,056 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Apache Camel 3.20.1 (camel-1) started in 1s396ms (build:0ms init:1s297ms start:99ms)
   [2] 2023-04-24 14:43:54,858 INFO  [io.quarkus] (main) camel-k-integration 1.12.0 on JVM (powered by Quarkus 2.16.0.Final) started in 42.794s. Listening on: http://0.0.0.0:8080
   [2] 2023-04-24 14:43:54,858 INFO  [io.quarkus] (main) Profile prod activated. 
   [2] 2023-04-24 14:43:54,859 INFO  [io.quarkus] (main) Installed features: [camel-attachments, camel-bean, camel-core, camel-direct, camel-java-joor-dsl, camel-k-core, camel-k-runtime, camel-kubernetes, camel-microprofile-health, camel-platform-http, camel-rest, camel-xml-io-dsl, cdi, kubernetes-client, security, smallrye-context-propagation, smallrye-health, vertx]
   [1] 2023-04-24 14:50:56,071 INFO  [org.apa.cam.k.Runtime] (main) Apache Camel K Runtime 1.17.0
   [1] 2023-04-24 14:50:56,072 INFO  [org.apa.cam.qua.cor.CamelBootstrapRecorder] (main) Bootstrap runtime: org.apache.camel.quarkus.main.CamelMainRuntime
   [1] 2023-04-24 14:50:56,072 INFO  [org.apa.cam.mai.MainSupport] (main) Apache Camel (Main) 3.20.1 is starting
   [1] 2023-04-24 14:50:56,076 INFO  [org.apa.cam.k.lis.SourcesConfigurer] (main) Loading routes from: SourceDefinition{name='test-one-openapi', language='xml', type='source', location='file:/etc/camel/sources/test-one-openapi.xml', }
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Apache Camel 3.20.1 (camel-1) is starting
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Routes startup (started:4)
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started mertGet (direct://mertGet)
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started mertPost (direct://mertPost)
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started route1 (rest://get:/mert)
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main)     Started route2 (rest://post:/mert)
   [1] 2023-04-24 14:50:56,091 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (main) Apache Camel 3.20.1 (camel-1) started in 2ms (build:0ms init:2ms start:0ms)
   [1] 2023-04-24 14:50:56,152 INFO  [io.quarkus] (main) camel-k-integration 1.12.0 native (powered by Quarkus 2.16.0.Final) started in 0.174s. Listening on: http://0.0.0.0:8080
   [1] 2023-04-24 14:50:56,152 INFO  [io.quarkus] (main) Profile prod activated. 
   [1] 2023-04-24 14:50:56,152 INFO  [io.quarkus] (main) Installed features: [camel-attachments, camel-bean, camel-core, camel-direct, camel-java-joor-dsl, camel-k-core, camel-k-runtime, camel-kubernetes, camel-microprofile-health, camel-platform-http, camel-rest, camel-xml-io-dsl, cdi, kubernetes-client, security, smallrye-context-propagation, smallrye-health, vertx]
   [2] 2023-04-24 14:50:56,430 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread) Apache Camel 3.20.1 (camel-1) is shutting down (timeout:45s)
   [2] 2023-04-24 14:50:56,463 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread) Routes stopped (stopped:4)
   [2] 2023-04-24 14:50:56,463 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread)     Stopped route2 (rest://post:/mert)
   [2] 2023-04-24 14:50:56,463 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread)     Stopped route1 (rest://get:/mert)
   [2] 2023-04-24 14:50:56,464 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread)     Stopped mertPost (direct://mertPost)
   [2] 2023-04-24 14:50:56,464 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread)     Stopped mertGet (direct://mertGet)
   [2] 2023-04-24 14:50:56,467 INFO  [org.apa.cam.imp.eng.AbstractCamelContext] (Shutdown thread) Apache Camel 3.20.1 (camel-1) shutdown in 36ms (uptime:7m2s)
   [2] 2023-04-24 14:50:56,856 INFO  [io.quarkus] (Shutdown thread) camel-k-integration stopped in 0.473s
   ```
   For some reason, the JVM mode was enabled forcefully (although it was not really required by my execution with `-t quarkus.package-type=native`). And it seems that the native execution does not start until the other JVM mode was started. I think we may have some kind of bug.
   
   @mertdotcc while we keep having a look, you may keep working on JVM mode only.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org