I am using quarkus to build a native image inside docker so its built as a linux executable as I need to run it inside kubernetes. And my host is osx laptop.
I am trying the camel-quarkus/examples/http-log and run the following and it outputs
โฏ mvn package -Pnative -Dquarkus.native.container-build=true
[INFO] Scanning for projects...
[INFO]
[INFO] ------< org.apache.camel.quarkus:camel-quarkus-examples-http-log >------
[INFO] Building Camel Quarkus :: Examples :: HTTP Log 1.1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- directory-maven-plugin:0.3.1:highest-basedir (directories) @ camel-quarkus-examples-http-log ---
[INFO] Highest basedir set to: /Users/davsclaus/workspace/camel-quarkus
[INFO]
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (camel-quarkus-enforcer-rules) @ camel-quarkus-examples-http-log ---
[INFO]
[INFO] --- groovy-maven-plugin:2.1.1:execute (sanity-checks) @ camel-quarkus-examples-http-log ---
[INFO]
[INFO] --- formatter-maven-plugin:2.11.0:format (format) @ camel-quarkus-examples-http-log ---
[INFO] Using 'UTF-8' encoding to format source files.
[INFO] Number of files to be formatted: 2
[INFO] Successfully formatted: 0 file(s)
[INFO] Fail to format: 0 file(s)
[INFO] Skipped: 2 file(s)
[INFO] Read only skipped: 0 file(s)
[INFO] Approximate time taken: 1s
[INFO]
[INFO] --- impsort-maven-plugin:1.3.2:sort (sort-imports) @ camel-quarkus-examples-http-log ---
[INFO] Total Files Processed: 2 in 00:00.250
[INFO] Already Sorted: 2
[INFO] Needed Sorting: 0
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:resources (default-resources) @ camel-quarkus-examples-http-log ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.0:compile (default-compile) @ camel-quarkus-examples-http-log ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:resources (copy-generated-resources) @ camel-quarkus-examples-http-log ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:testResources (default-testResources) @ camel-quarkus-examples-http-log ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /Users/davsclaus/workspace/camel-quarkus/examples/http-log/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.0:testCompile (default-testCompile) @ camel-quarkus-examples-http-log ---
[INFO] No sources to compile
[INFO]
[INFO] --- maven-surefire-plugin:2.22.2:test (default-test) @ camel-quarkus-examples-http-log ---
[INFO] No tests to run.
[INFO]
[INFO] --- maven-jar-plugin:3.2.0:jar (default-jar) @ camel-quarkus-examples-http-log ---
[INFO]
[INFO] --- maven-site-plugin:3.7.1:attach-descriptor (attach-descriptor) @ camel-quarkus-examples-http-log ---
[INFO] Skipping because packaging 'jar' is not pom.
[INFO]
[INFO] --- quarkus-maven-plugin:1.4.0.CR1:build (build) @ camel-quarkus-examples-http-log ---
[INFO] [org.jboss.threads] JBoss Threads version 3.0.1.Final
[INFO] Initializing dekorate session.
[INFO] Default s2i build generator....
[INFO] Generating manifests.
[INFO] Processing kubernetes configuration.
[INFO] Processing openshift configuration.
[INFO] Processing s2i configuration.
[INFO] Closing dekorate session.
[INFO] [io.quarkus.deployment.pkg.steps.JarResultBuildStep] Building native image source jar: /Users/davsclaus/workspace/camel-quarkus/examples/http-log/target/camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-native-image-source-jar/camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner.jar
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Building native image from /Users/davsclaus/workspace/camel-quarkus/examples/http-log/target/camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-native-image-source-jar/camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner.jar
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Pulling image quay.io/quarkus/ubi-quarkus-native-image:19.3.1-java11
19.3.1-java11: Pulling from quarkus/ubi-quarkus-native-image
57de4da701b5: Pull complete
cf0f3ebe9f53: Pull complete
e9da77aa316d: Pull complete
Digest: sha256:b18b701bd6f9d0a7778129f63b9f2dd666be2a2574854b56cd60e3cbd42b73d3
Status: Downloaded newer image for quay.io/quarkus/ubi-quarkus-native-image:19.3.1-java11
quay.io/quarkus/ubi-quarkus-native-image:19.3.1-java11
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Running Quarkus native-image plugin on GraalVM Version 19.3.1 CE
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] docker run -v /Users/davsclaus/workspace/camel-quarkus/examples/http-log/target/camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-native-image-source-jar:/project:z --env LANG=C --rm quay.io/quarkus/ubi-quarkus-native-image:19.3.1-java11 -J-Dsun.nio.ch.maxUpdateArraySize=100 -J-Djava.util.logging.manager=org.jboss.logmanager.LogManager -J-Dvertx.logger-delegate-factory-class-name=io.quarkus.vertx.core.runtime.VertxLogDelegateFactory -J-Dvertx.disableDnsResolver=true -J-Dio.netty.leakDetection.level=DISABLED -J-Dio.netty.allocator.maxOrder=1 -J-Duser.language=en -J-Dfile.encoding=UTF-8 --initialize-at-build-time= -H:InitialCollectionPolicy=com.oracle.svm.core.genscavenge.CollectionPolicy$BySpaceAndTime -H:+JNI -jar camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner.jar -H:FallbackThreshold=0 -H:+ReportExceptionStackTraces -H:-AddAllCharsets -H:-IncludeAllTimeZones -H:EnableURLProtocols=http --no-server -H:-UseServiceLoaderFeature -H:+StackTrace camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] classlist: 16,531.68 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (cap): 1,514.76 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] setup: 3,546.12 ms
14:59:47,949 INFO [org.jbo.threads] JBoss Threads version 3.0.1.Final
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (typeflow): 882,776.03 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (objects): 416,375.82 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (features): 13,157.75 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] analysis: 1,334,444.53 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (clinit): 123,905.33 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] universe: 299,859.31 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (parse): 22,680.13 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (inline): 68,547.25 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] (compile): 133,301.39 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] compile: 240,191.60 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] image: 11,259.32 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] write: 3,254.87 ms
[camel-quarkus-examples-http-log-1.1.0-SNAPSHOT-runner:24] [total]: 1,932,292.10 ms
[INFO] [io.quarkus.deployment.QuarkusAugmentor] Quarkus augmentation completed in 2024639ms
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 33:54 min
[INFO] Finished at: 2020-04-18T17:30:59+02:00
[INFO] ------------------------------------------------------------------------
I would have thought that the native image builder will use a container image with a graalvm 20.0.0 CE version.
Is there any plans to get this updated before the final release?
PS: The build time is very long as docker was set to 4gb of memory.
Quarkus has support for bot 19.3.1 and 20.0.0 (which is still experimental, IIRC @gwenneg right?) of GraalVM.
The default builder image is quay.io/quarkus/ubi-quarkus-native-image:19.3.1-java11. To switch to using 20.0.0, you can change the builder image to quay.io/quarkus/ubi-quarkus-native-image:20.0.0-java11 using the quarkus.native.builder-image configuration knob.
That's correct @machi1990.
Thanks for the feedback.
btw see also #1610 about struggle to build native image in kubernetes.
Closing as clarified in https://github.com/quarkusio/quarkus/issues/8669#issuecomment-615951025. Thanks!