Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

During IT: Redis host not configured #40805

Open
johnmanko opened this issue May 22, 2024 · 9 comments
Open

During IT: Redis host not configured #40805

johnmanko opened this issue May 22, 2024 · 9 comments
Labels
area/native-image kind/bug Something isn't working triage/needs-feedback We are waiting for feedback.

Comments

@johnmanko
Copy link

Describe the bug

I'm attempting to add integration tests to a project, but I can't get it when extension container-image-docker is installed.

It errors with Redis host not configured - you must either configure 'quarkus.redis.hosts or 'quarkus.redis.host-provider-name' and have a bean providing the hosts programmatically.`


Testing against the mock @QuarkusTest tests runs fine: ./mvnw verify

[INFO] -------------------------------------------------------                                                                                                                                             
[INFO]  T E S T S                                                                                                                                                                                          
[INFO] -------------------------------------------------------                                                                                                                                             
[INFO] |                                                                                                                                                                                                   
[INFO] +-- Data REST Resource
[INFO] | +-- [OK] Endpoint: GET /data - 0.777 ss
[INFO] |
[INFO] +-- Hello REST Resource
[INFO] | +-- [OK] Endpoint: GET /hello - 0.018 ss
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0

Testing again integration @QuarkusIntegrationTest with plugin container-image-docker runs: ./mvnw verify -Dnative -Dquarkus.container-image.build=true:

❯ ./mvnw verify -Dnative -Dquarkus.container-image.build=true                                                                                                                                              
Warning: JAVA_HOME environment variable is not set.                                                                                                                                                        
[INFO] Scanning for projects...                                                                                                                                                                            
[INFO] 
[INFO] ------------< com.johnmanko:quarkus-redis-service-example >-------------
[INFO] Building quarkus-redis-service-example 1.0.0-SNAPSHOT
[INFO]   from pom.xml
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- resources:3.3.1:resources (default-resources) @ quarkus-redis-service-example ---
[INFO] Copying 1 resource from src/main/resources to target/classes
[INFO] 
[INFO] --- quarkus:3.10.0:generate-code (default) @ quarkus-redis-service-example ---
[INFO] 
[INFO] --- compiler:3.12.1:compile (default-compile) @ quarkus-redis-service-example ---
[INFO] Nothing to compile - all classes are up to date.
[INFO] 
[INFO] --- quarkus:3.10.0:generate-code-tests (default) @ quarkus-redis-service-example ---
[INFO] 
[INFO] --- resources:3.3.1:testResources (default-testResources) @ quarkus-redis-service-example ---
[INFO] skip non existing resourceDirectory /path/to/projects/github/quarkus-redis-service-example/src/test/resources
[INFO] 
[INFO] --- compiler:3.12.1:testCompile (default-testCompile) @ quarkus-redis-service-example ---
[INFO] Nothing to compile - all classes are up to date.
[INFO] 
[INFO] --- surefire:3.2.5:test (default-test) @ quarkus-redis-service-example ---
[INFO] Using auto detected provider org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
[INFO] 
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] |
[INFO] +-- Data REST Resource
[INFO] | +-- [OK] Endpoint: GET /data - 0.788 ss
[INFO] |
[INFO] +-- Hello REST Resource
[INFO] | +-- [OK] Endpoint: GET /hello - 0.019 ss
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0
[INFO] 
[INFO] 
[INFO] --- jar:3.3.0:jar (default-jar) @ quarkus-redis-service-example ---
[INFO] Building jar: /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT.jar
[INFO] 
[INFO] --- quarkus:3.10.0:build (default) @ quarkus-redis-service-example ---
[WARNING] [io.quarkus.config] Unrecognized configuration key "quarkus.container-image.build" was provided; it will be ignored; verify that the dependency extension for this configuration is set or that you did not make a typo
[WARNING] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Cannot find the `native-image` in the GRAALVM_HOME, JAVA_HOME and System PATH. Install it using `gu install native-image` Attempting to fall back to container build.
[INFO] [io.quarkus.deployment.pkg.steps.JarResultBuildStep] Building native image source jar: /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner.jar
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Building native image from /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner.jar
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildContainerRunner] Using docker to run the native image builder
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildContainerRunner] Pulling builder image 'quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21'
jdk-21: Pulling from quarkus/ubi-quarkus-mandrel-builder-image
Digest: sha256:9c134352bb0fcc04f6de0bbbda0d32b27b61d564b7c3140d09687269dc57e197
Status: Image is up to date for quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21
quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21

What's Next?
  1. Sign in to your Docker account → docker login
  2. View a summary of image vulnerabilities and recommendations → docker scout quickview quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Running Quarkus native-image plugin on MANDREL 23.1.3.1 JDK 21.0.3+9-LTS
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildRunner] docker run --env LANG=C --rm --user 0 -v /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar:/project:z --name build-native-KspLE quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21 -J-Dsun.nio.ch.maxUpdateArraySize=100 -J-Djava.util.logging.manager=org.jboss.logmanager.LogManager -J-Dlogging.initial-configurator.min-level=500 -J-Dio.netty.leakDetection.level=DISABLED -J-Dio.netty.allocator.maxOrder=3 -J-Dvertx.logger-delegate-factory-class-name=io.quarkus.vertx.core.runtime.VertxLogDelegateFactory -J-Dvertx.disableDnsResolver=true -J-Duser.language=en -J-Duser.country=US -J-Dfile.encoding=UTF-8 --features=io.quarkus.runner.Feature,io.quarkus.runtime.graal.DisableLoggingFeature -J--add-exports=java.security.jgss/sun.security.krb5=ALL-UNNAMED -J--add-opens=java.base/java.text=ALL-UNNAMED -J--add-opens=java.base/java.io=ALL-UNNAMED -J--add-opens=java.base/java.lang.invoke=ALL-UNNAMED -J--add-opens=java.base/java.util=ALL-UNNAMED -H:+UnlockExperimentalVMOptions -H:BuildOutputJSONFile=quarkus-redis-service-example-1.0.0-SNAPSHOT-runner-build-output-stats.json -H:-UnlockExperimentalVMOptions --strict-image-heap -H:+UnlockExperimentalVMOptions -H:+AllowFoldMethods -H:-UnlockExperimentalVMOptions -J-Djava.awt.headless=true --no-fallback --link-at-build-time -H:+UnlockExperimentalVMOptions -H:+ReportExceptionStackTraces -H:-UnlockExperimentalVMOptions -H:-AddAllCharsets --enable-url-protocols=http,https --enable-monitoring=heapdump -H:+UnlockExperimentalVMOptions -H:-UseServiceLoaderFeature -H:-UnlockExperimentalVMOptions -J--add-exports=org.graalvm.nativeimage/org.graalvm.nativeimage.impl=ALL-UNNAMED --exclude-config io\.netty\.netty-codec /META-INF/native-image/io\.netty/netty-codec/generated/handlers/reflect-config\.json --exclude-config io\.netty\.netty-handler /META-INF/native-image/io\.netty/netty-handler/generated/handlers/reflect-config\.json quarkus-redis-service-example-1.0.0-SNAPSHOT-runner -jar quarkus-redis-service-example-1.0.0-SNAPSHOT-runner.jar
========================================================================================================================
GraalVM Native Image: Generating 'quarkus-redis-service-example-1.0.0-SNAPSHOT-runner' (executable)...
========================================================================================================================
For detailed information and explanations on the build output, visit:
https://github.com/oracle/graal/blob/master/docs/reference-manual/native-image/BuildOutput.md
------------------------------------------------------------------------------------------------------------------------
[1/8] Initializing...                                                                                    (4.2s @ 0.16GB)
 Java version: 21.0.3+9-LTS, vendor version: Mandrel-23.1.3.1-Final
 Graal compiler: optimization level: 2, target machine: x86-64-v3
 C compiler: gcc (redhat, x86_64, 8.5.0)
 Garbage collector: Serial GC (max heap size: 80% of RAM)
 3 user-specific feature(s):
 - com.oracle.svm.thirdparty.gson.GsonFeature
 - io.quarkus.runner.Feature: Auto-generated class by Quarkus from the existing extensions
 - io.quarkus.runtime.graal.DisableLoggingFeature: Disables INFO logging during the analysis phase
------------------------------------------------------------------------------------------------------------------------
 3 experimental option(s) unlocked:
 - '-H:+AllowFoldMethods' (origin(s): command line)
 - '-H:BuildOutputJSONFile' (origin(s): command line)
 - '-H:-UseServiceLoaderFeature' (origin(s): command line)
------------------------------------------------------------------------------------------------------------------------
Build resources:
 - 16.92GB of memory (61.7% of 27.42GB system memory, determined at start)
 - 8 thread(s) (100.0% of 8 available processor(s), determined at start)
[2/8] Performing analysis...  [*****]                                                                   (21.6s @ 1.01GB)
   12,590 reachable types   (87.0% of   14,475 total)
   18,290 reachable fields  (58.8% of   31,112 total)
   65,127 reachable methods (54.4% of  119,809 total)
    3,930 types,   137 fields, and 3,591 methods registered for reflection
       61 types,    61 fields, and    55 methods registered for JNI access
        4 native libraries: dl, pthread, rt, z
[3/8] Building universe...                                                                               (4.4s @ 1.43GB)
[4/8] Parsing methods...      [**]                                                                       (2.2s @ 1.88GB)
[5/8] Inlining methods...     [***]                                                                      (1.3s @ 1.36GB)
[6/8] Compiling methods...    [****]                                                                    (16.7s @ 1.67GB)
[7/8] Layouting methods...    [**]                                                                       (3.4s @ 1.35GB)
[8/8] Creating image...       [**]                                                                       (4.7s @ 1.88GB)
  26.14MB (47.30%) for code area:    42,246 compilation units
  28.73MB (51.99%) for image heap:  326,006 objects and 56 resources
 403.43kB ( 0.71%) for other data
  55.27MB in total
------------------------------------------------------------------------------------------------------------------------
Top 10 origins of code area:                                Top 10 object types in image heap:
  12.76MB java.base                                            8.39MB byte[] for code metadata
   1.92MB c.f.jackson.core.jackson-databind-2.17.0.jar         4.34MB byte[] for java.lang.String
   1.38MB svm.jar (Native Image)                               3.14MB java.lang.Class
   1.17MB q.0.0-SNAPSHOT-runner.jar                            2.96MB java.lang.String
   1.05MB modified-io.vertx.vertx-core-4.5.7.jar               1.06MB byte[] for general heap data
 591.41kB com.fasterxml.jackson.core.jackson-core-2.17.0.jar   1.06MB com.oracle.svm.core.hub.DynamicHubCompanion
 512.42kB io.netty.netty-buffer-4.1.108.Final.jar            748.35kB byte[] for reflection metadata
 504.89kB io.netty.netty-common-4.1.108.Final.jar            589.57kB java.lang.String[]
 439.36kB io.netty.netty-codec-http-4.1.108.Final.jar        489.23kB java.util.HashMap$Node
 409.14kB io.netty.netty-transport-4.1.108.Final.jar         457.34kB c.o.svm.core.hub.DynamicHub$ReflectionMetadata
   5.14MB for 90 more packages                                 5.56MB for 3175 more object types
------------------------------------------------------------------------------------------------------------------------
Recommendations:
 HEAP: Set max heap for improved and more predictable memory usage.
 CPU:  Enable more CPU features with '-march=native' for improved performance.
------------------------------------------------------------------------------------------------------------------------
                        4.9s (8.2% of total time) in 76 GCs | Peak RSS: 3.53GB | CPU load: 6.18
------------------------------------------------------------------------------------------------------------------------
Produced artifacts:
 /project/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner (executable)
 /project/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner-build-output-stats.json (build_info)
========================================================================================================================
Finished generating 'quarkus-redis-service-example-1.0.0-SNAPSHOT-runner' in 59.2s.
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildRunner] docker run --env LANG=C --rm --user 0 -v /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar:/project:z --entrypoint /bin/bash quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21 -c objcopy --strip-debug quarkus-redis-service-example-1.0.0-SNAPSHOT-runner
[INFO] [io.quarkus.deployment.QuarkusAugmentor] Quarkus augmentation completed in 65344ms
[INFO] 
[INFO] --- failsafe:3.2.5:integration-test (default) @ quarkus-redis-service-example ---
[INFO] Using auto detected provider org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
[INFO] 
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running com.johnmanko.service.data.DataEndpointResourceIT
Executing "/path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner -Dquarkus.http.port=8081 -Dquarkus.http.ssl-port=8444 -Dtest.url=http://localhost:8081 -Dquarkus.log.file.path=/path/to/projects/github/quarkus-redis-service-example/target/quarkus.log -Dquarkus.log.file.enable=true -Dquarkus.log.category."io.quarkus".level=INFO -Dquarkus.container-image.build=true"
__  ____  __  _____   ___  __ ____  ______ 
 --/ __ \/ / / / _ | / _ \/ //_/ / / / __/ 
 -/ /_/ / /_/ / __ |/ , _/ ,< / /_/ /\ \   
--\___\_\____/_/ |_/_/|_/_/|_|\____/___/   
2024-05-22 16:55:41,021 WARN  [io.qua.config] (main) Unrecognized configuration key "quarkus.container-image.build" was provided; it will be ignored; verify that the dependency extension for this configuration is set or that you did not make a typo
2024-05-22 16:55:41,026 INFO  [io.quarkus] (main) quarkus-redis-service-example 1.0.0-SNAPSHOT native (powered by Quarkus 3.10.0) started in 0.014s. Listening on: http://0.0.0.0:8081
2024-05-22 16:55:41,027 INFO  [io.quarkus] (main) Profile prod activated. 
2024-05-22 16:55:41,027 INFO  [io.quarkus] (main) Installed features: [cdi, redis-client, rest, rest-jackson, smallrye-context-propagation, vertx]
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.577 s -- in com.johnmanko.service.data.DataEndpointResourceIT
[INFO] Running com.johnmanko.service.data.HelloEndpointResourceIT
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.021 s -- in com.johnmanko.service.data.HelloEndpointResourceIT
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0
[INFO] 
[INFO] 
[INFO] --- failsafe:3.2.5:verify (default) @ quarkus-redis-service-example ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  01:17 min
[INFO] Finished at: 2024-05-22T16:55:42-04:00
[INFO] ------------------------------------------------------------------------
                                                               

Now, adding the following extension and rerunning the IT native tests:

❯ quarkus extension add container-image-docker                                                                                                                                                             
[SUCCESS] ✅  Extension io.quarkus:quarkus-container-image-docker has been installed                                                                                                                        
./mvnw verify -Dnative -Dquarkus.container-image.build=true 
Warning: JAVA_HOME environment variable is not set.                                                                                                                                                        
[INFO] Scanning for projects...                                                                                                                                                                            
[INFO] 
[INFO] ------------< com.johnmanko:quarkus-redis-service-example >-------------
[INFO] Building quarkus-redis-service-example 1.0.0-SNAPSHOT
[INFO]   from pom.xml
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- resources:3.3.1:resources (default-resources) @ quarkus-redis-service-example ---
[INFO] Copying 1 resource from src/main/resources to target/classes
[INFO] 
[INFO] --- quarkus:3.10.0:generate-code (default) @ quarkus-redis-service-example ---
[INFO] 
[INFO] --- compiler:3.12.1:compile (default-compile) @ quarkus-redis-service-example ---
[INFO] Nothing to compile - all classes are up to date.
[INFO] 
[INFO] --- quarkus:3.10.0:generate-code-tests (default) @ quarkus-redis-service-example ---
[INFO] 
[INFO] --- resources:3.3.1:testResources (default-testResources) @ quarkus-redis-service-example ---
[INFO] skip non existing resourceDirectory /path/to/projects/github/quarkus-redis-service-example/src/test/resources
[INFO] 
[INFO] --- compiler:3.12.1:testCompile (default-testCompile) @ quarkus-redis-service-example ---
[INFO] Nothing to compile - all classes are up to date.
[INFO] 
[INFO] --- surefire:3.2.5:test (default-test) @ quarkus-redis-service-example ---
[INFO] Using auto detected provider org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
[INFO] 
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] |
[INFO] +-- Data REST Resource
[INFO] | +-- [OK] Endpoint: GET /data - 0.837 ss
[INFO] |
[INFO] +-- Hello REST Resource
[INFO] | +-- [OK] Endpoint: GET /hello - 0.025 ss
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0
[INFO] 
[INFO] 
[INFO] --- jar:3.3.0:jar (default-jar) @ quarkus-redis-service-example ---
[INFO] Building jar: /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT.jar
[INFO] 
[INFO] --- quarkus:3.10.0:build (default) @ quarkus-redis-service-example ---
[WARNING] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Cannot find the `native-image` in the GRAALVM_HOME, JAVA_HOME and System PATH. Install it using `gu install native-image` Attempting to fall back to container build.
[INFO] [io.quarkus.deployment.pkg.steps.JarResultBuildStep] Building native image source jar: /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner.jar
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Building native image from /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner.jar
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildContainerRunner] Using docker to run the native image builder
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildContainerRunner] Pulling builder image 'quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21'
jdk-21: Pulling from quarkus/ubi-quarkus-mandrel-builder-image
Digest: sha256:9c134352bb0fcc04f6de0bbbda0d32b27b61d564b7c3140d09687269dc57e197
Status: Image is up to date for quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21
quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21

What's Next?
  1. Sign in to your Docker account → docker login
  2. View a summary of image vulnerabilities and recommendations → docker scout quickview quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildStep] Running Quarkus native-image plugin on MANDREL 23.1.3.1 JDK 21.0.3+9-LTS
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildRunner] docker run --env LANG=C --rm --user 0 -v /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar:/project:z --name build-native-GdKgZ quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21 -J-Dsun.nio.ch.maxUpdateArraySize=100 -J-Djava.util.logging.manager=org.jboss.logmanager.LogManager -J-Dlogging.initial-configurator.min-level=500 -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=3 -J-Duser.language=en -J-Duser.country=US -J-Dfile.encoding=UTF-8 --features=io.quarkus.runner.Feature,io.quarkus.runtime.graal.DisableLoggingFeature -J--add-exports=java.security.jgss/sun.security.krb5=ALL-UNNAMED -J--add-opens=java.base/java.text=ALL-UNNAMED -J--add-opens=java.base/java.io=ALL-UNNAMED -J--add-opens=java.base/java.lang.invoke=ALL-UNNAMED -J--add-opens=java.base/java.util=ALL-UNNAMED -H:+UnlockExperimentalVMOptions -H:BuildOutputJSONFile=quarkus-redis-service-example-1.0.0-SNAPSHOT-runner-build-output-stats.json -H:-UnlockExperimentalVMOptions --strict-image-heap -H:+UnlockExperimentalVMOptions -H:+AllowFoldMethods -H:-UnlockExperimentalVMOptions -J-Djava.awt.headless=true --no-fallback --link-at-build-time -H:+UnlockExperimentalVMOptions -H:+ReportExceptionStackTraces -H:-UnlockExperimentalVMOptions -H:-AddAllCharsets --enable-url-protocols=http,https --enable-monitoring=heapdump -H:+UnlockExperimentalVMOptions -H:-UseServiceLoaderFeature -H:-UnlockExperimentalVMOptions -J--add-exports=org.graalvm.nativeimage/org.graalvm.nativeimage.impl=ALL-UNNAMED --exclude-config io\.netty\.netty-codec /META-INF/native-image/io\.netty/netty-codec/generated/handlers/reflect-config\.json --exclude-config io\.netty\.netty-handler /META-INF/native-image/io\.netty/netty-handler/generated/handlers/reflect-config\.json quarkus-redis-service-example-1.0.0-SNAPSHOT-runner -jar quarkus-redis-service-example-1.0.0-SNAPSHOT-runner.jar
========================================================================================================================
GraalVM Native Image: Generating 'quarkus-redis-service-example-1.0.0-SNAPSHOT-runner' (executable)...
========================================================================================================================
For detailed information and explanations on the build output, visit:
https://github.com/oracle/graal/blob/master/docs/reference-manual/native-image/BuildOutput.md
------------------------------------------------------------------------------------------------------------------------
[1/8] Initializing...                                                                                    (4.2s @ 0.16GB)
 Java version: 21.0.3+9-LTS, vendor version: Mandrel-23.1.3.1-Final
 Graal compiler: optimization level: 2, target machine: x86-64-v3
 C compiler: gcc (redhat, x86_64, 8.5.0)
 Garbage collector: Serial GC (max heap size: 80% of RAM)
 3 user-specific feature(s):
 - com.oracle.svm.thirdparty.gson.GsonFeature
 - io.quarkus.runner.Feature: Auto-generated class by Quarkus from the existing extensions
 - io.quarkus.runtime.graal.DisableLoggingFeature: Disables INFO logging during the analysis phase
------------------------------------------------------------------------------------------------------------------------
 3 experimental option(s) unlocked:
 - '-H:+AllowFoldMethods' (origin(s): command line)
 - '-H:BuildOutputJSONFile' (origin(s): command line)
 - '-H:-UseServiceLoaderFeature' (origin(s): command line)
------------------------------------------------------------------------------------------------------------------------
Build resources:
 - 16.86GB of memory (61.5% of 27.42GB system memory, determined at start)
 - 8 thread(s) (100.0% of 8 available processor(s), determined at start)
[2/8] Performing analysis...  [*****]                                                                   (21.9s @ 0.98GB)
   12,590 reachable types   (87.0% of   14,474 total)
   18,290 reachable fields  (58.8% of   31,112 total)
   65,132 reachable methods (54.4% of  119,820 total)
    3,930 types,   137 fields, and 3,591 methods registered for reflection
       61 types,    61 fields, and    55 methods registered for JNI access
        4 native libraries: dl, pthread, rt, z
[3/8] Building universe...                                                                               (3.4s @ 1.57GB)
[4/8] Parsing methods...      [**]                                                                       (2.3s @ 1.52GB)
[5/8] Inlining methods...     [***]                                                                      (1.3s @ 1.84GB)
[6/8] Compiling methods...    [****]                                                                    (17.2s @ 1.61GB)
[7/8] Layouting methods...    [**]                                                                       (3.6s @ 1.41GB)
[8/8] Creating image...       [***]                                                                      (5.3s @ 1.33GB)
  26.15MB (47.30%) for code area:    42,252 compilation units
  28.74MB (51.98%) for image heap:  326,110 objects and 56 resources
 404.32kB ( 0.71%) for other data
  55.28MB in total
------------------------------------------------------------------------------------------------------------------------
Top 10 origins of code area:                                Top 10 object types in image heap:
  12.76MB java.base                                            8.39MB byte[] for code metadata
   1.92MB c.f.jackson.core.jackson-databind-2.17.0.jar         4.34MB byte[] for java.lang.String
   1.38MB svm.jar (Native Image)                               3.14MB java.lang.Class
   1.18MB q.0.0-SNAPSHOT-runner.jar                            2.96MB java.lang.String
   1.05MB modified-io.vertx.vertx-core-4.5.7.jar               1.06MB byte[] for general heap data
 591.41kB com.fasterxml.jackson.core.jackson-core-2.17.0.jar   1.06MB com.oracle.svm.core.hub.DynamicHubCompanion
 512.44kB io.netty.netty-buffer-4.1.108.Final.jar            748.41kB byte[] for reflection metadata
 504.96kB io.netty.netty-common-4.1.108.Final.jar            589.77kB java.lang.String[]
 439.36kB io.netty.netty-codec-http-4.1.108.Final.jar        490.27kB java.util.HashMap$Node
 409.13kB io.netty.netty-transport-4.1.108.Final.jar         457.34kB c.o.svm.core.hub.DynamicHub$ReflectionMetadata
   5.14MB for 90 more packages                                 5.56MB for 3175 more object types
------------------------------------------------------------------------------------------------------------------------
Recommendations:
 HEAP: Set max heap for improved and more predictable memory usage.
 CPU:  Enable more CPU features with '-march=native' for improved performance.
------------------------------------------------------------------------------------------------------------------------
                        4.8s (8.0% of total time) in 153 GCs | Peak RSS: 3.53GB | CPU load: 6.18
------------------------------------------------------------------------------------------------------------------------
Produced artifacts:
 /project/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner (executable)
 /project/quarkus-redis-service-example-1.0.0-SNAPSHOT-runner-build-output-stats.json (build_info)
========================================================================================================================
Finished generating 'quarkus-redis-service-example-1.0.0-SNAPSHOT-runner' in 59.9s.
[INFO] [io.quarkus.deployment.pkg.steps.NativeImageBuildRunner] docker run --env LANG=C --rm --user 0 -v /path/to/projects/github/quarkus-redis-service-example/target/quarkus-redis-service-example-1.0.0-SNAPSHOT-native-image-source-jar:/project:z --entrypoint /bin/bash quay.io/quarkus/ubi-quarkus-mandrel-builder-image:jdk-21 -c objcopy --strip-debug quarkus-redis-service-example-1.0.0-SNAPSHOT-runner
[INFO] Loaded org.testcontainers.dockerclient.UnixSocketClientProviderStrategy from ~/.testcontainers.properties, will try it first
[INFO] Found Docker environment with local Unix socket (unix:///var/run/docker.sock)
[INFO] Docker host IP address is localhost
[INFO] Connected to docker: 
  Server Version: 26.1.2
  API Version: 1.45
  Operating System: Ubuntu 23.10
  Total Memory: 64225 MB
[INFO] Image pull policy will be performed by: DefaultPullPolicy()
[INFO] Image name substitution will be performed by: DefaultImageNameSubstitutor (composite of 'ConfigurationFileImageNameSubstitutor' and 'PrefixingImageNameSubstitutor')
[INFO] Checking the system...
[INFO] ✔︎ Docker server version should be at least 1.6.0
[INFO] [io.quarkus.container.image.docker.deployment.DockerProcessor] Starting (local) container image build for native binary using docker.
[INFO] [io.quarkus.container.image.docker.deployment.DockerProcessor] Executing the following command to build docker image: 'docker build -f /path/to/projects/github/quarkus-redis-service-example/src/main/docker/Dockerfile.native -t john/quarkus-redis-service-example:1.0.0-SNAPSHOT /path/to/projects/github/quarkus-redis-service-example'
[INFO] [io.quarkus.deployment.util.ExecUtil] #0 building with "desktop-linux" instance using docker driver
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #1 [internal] load build definition from Dockerfile.native
[INFO] [io.quarkus.deployment.util.ExecUtil] #1 transferring dockerfile: 750B done
[INFO] [io.quarkus.deployment.util.ExecUtil] #1 DONE 0.0s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #2 [internal] load .dockerignore
[INFO] [io.quarkus.deployment.util.ExecUtil] #2 transferring context: 115B done
[INFO] [io.quarkus.deployment.util.ExecUtil] #2 DONE 0.0s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #3 [internal] load metadata for registry.access.redhat.com/ubi8/ubi-minimal:8.9
[INFO] [io.quarkus.deployment.util.ExecUtil] #3 DONE 0.5s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #4 [1/4] FROM registry.access.redhat.com/ubi8/ubi-minimal:8.9@sha256:2fa47fa9df7b98e2776f447855699c01d06c3271b2d7259b8b314084580cf591
[INFO] [io.quarkus.deployment.util.ExecUtil] #4 DONE 0.0s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #5 [internal] load build context
[INFO] [io.quarkus.deployment.util.ExecUtil] #5 transferring context: 57.83MB 0.3s done
[INFO] [io.quarkus.deployment.util.ExecUtil] #5 DONE 0.4s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #6 [2/4] WORKDIR /work/
[INFO] [io.quarkus.deployment.util.ExecUtil] #6 CACHED
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #7 [3/4] RUN chown 1001 /work     && chmod "g+rwX" /work     && chown 1001:root /work
[INFO] [io.quarkus.deployment.util.ExecUtil] #7 CACHED
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #8 [4/4] COPY --chown=1001:root target/*-runner /work/application
[INFO] [io.quarkus.deployment.util.ExecUtil] #8 DONE 0.1s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] #9 exporting to image
[INFO] [io.quarkus.deployment.util.ExecUtil] #9 exporting layers
[INFO] [io.quarkus.deployment.util.ExecUtil] #9 exporting layers 0.2s done
[INFO] [io.quarkus.deployment.util.ExecUtil] #9 writing image sha256:7e5e14ee3ff2170731e3e99b7d4ea65b4c994906f475e0d9eed97f92c2136ce8 done
[INFO] [io.quarkus.deployment.util.ExecUtil] #9 naming to docker.io/john/quarkus-redis-service-example:1.0.0-SNAPSHOT done
[INFO] [io.quarkus.deployment.util.ExecUtil] #9 DONE 0.2s
[INFO] [io.quarkus.deployment.util.ExecUtil] 
[INFO] [io.quarkus.deployment.util.ExecUtil] What's Next?
[INFO] [io.quarkus.deployment.util.ExecUtil]   1. Sign in to your Docker account → docker login
[INFO] [io.quarkus.deployment.util.ExecUtil]   2. View a summary of image vulnerabilities and recommendations → docker scout quickview
[INFO] [io.quarkus.container.image.docker.deployment.DockerProcessor] Built container image john/quarkus-redis-service-example:1.0.0-SNAPSHOT

[INFO] [io.quarkus.deployment.QuarkusAugmentor] Quarkus augmentation completed in 67669ms
[INFO] 
[INFO] --- failsafe:3.2.5:integration-test (default) @ quarkus-redis-service-example ---
[INFO] Using auto detected provider org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
[INFO] 
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running com.johnmanko.service.data.DataEndpointResourceIT
2024-05-22 17:00:45,789 WARN  [org.tes.doc.DockerClientProviderStrategy] (main) Can't instantiate a strategy from org.testcontainers.dockerclient.UnixSocketClientProviderStrategy (ClassNotFoundException). This probably means that cached configuration refers to a client provider class that is not available in this version of Testcontainers. Other strategies will be tried instead.
2024-05-22 17:00:45,790 ERROR [org.tes.doc.DockerClientProviderStrategy] (main) Could not find a valid Docker environment. Please check configuration. Attempted configurations were:
As no valid configuration was found, execution cannot continue.
See https://java.testcontainers.org/on_failure.html for more details.
2024-05-22 17:00:46,554 INFO  [io.qua.tes.com.DefaultDockerContainerLauncher] (main) Executing "docker run --name quarkus-integration-test-Dlbxl -i --rm -p 8081:8081 -p 8444:8444 --net=quarkus-integration-test-wZJCa --env QUARKUS_LOG_CATEGORY__IO_QUARKUS__LEVEL=INFO --env QUARKUS_HTTP_PORT=8081 --env QUARKUS_HTTP_SSL_PORT=8444 --env TEST_URL=http://localhost:8081 --env QUARKUS_CONTAINER_IMAGE_BUILD=true john/quarkus-redis-service-example:1.0.0-SNAPSHOT"
Waited 60 seconds for target/quarkus.log to contain info about the listening port and protocol but no such info was found. Check if the options quarkus.log.level and quarkus.log.file.level are at least INFO (or more verbose).
Failed to launch the application. The application logs can be found at: /path/to/projects/github/quarkus-redis-service-example/target/quarkus.log
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 62.45 s <<< FAILURE! -- in com.johnmanko.service.data.DataEndpointResourceIT
[ERROR] com.johnmanko.service.data.DataEndpointResourceIT.postLock -- Time elapsed: 0.007 s <<< ERROR!
java.lang.RuntimeException: java.lang.IllegalStateException: Unable to determine the status of the running process. See the above logs for details
        at io.quarkus.test.junit.QuarkusIntegrationTestExtension.throwBootFailureException(QuarkusIntegrationTestExtension.java:372)
        at io.quarkus.test.junit.QuarkusIntegrationTestExtension.beforeEach(QuarkusIntegrationTestExtension.java:117)
        at java.base/java.util.ArrayList.forEach(ArrayList.java:1597)
        at java.base/java.util.ArrayList.forEach(ArrayList.java:1597)
Caused by: java.lang.IllegalStateException: Unable to determine the status of the running process. See the above logs for details
        at io.quarkus.test.common.LauncherUtil.waitForCapturedListeningData(LauncherUtil.java:102)
        at io.quarkus.test.common.DefaultDockerContainerLauncher.start(DefaultDockerContainerLauncher.java:179)
        at io.quarkus.test.junit.IntegrationTestUtil.startLauncher(IntegrationTestUtil.java:195)
        at io.quarkus.test.junit.QuarkusIntegrationTestExtension.doProcessStart(QuarkusIntegrationTestExtension.java:300)
        at io.quarkus.test.junit.QuarkusIntegrationTestExtension.ensureStarted(QuarkusIntegrationTestExtension.java:169)
        at io.quarkus.test.junit.QuarkusIntegrationTestExtension.postProcessTestInstance(QuarkusIntegrationTestExtension.java:327)
        at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
        at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:179)
        at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1709)
        at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
        at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
        at java.base/java.util.stream.StreamSpliterators$WrappingSpliterator.forEachRemaining(StreamSpliterators.java:310)
        at java.base/java.util.stream.Streams$ConcatSpliterator.forEachRemaining(Streams.java:735)
        at java.base/java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:762)
        at java.base/java.util.Optional.orElseGet(Optional.java:364)
        ... 1 more

[INFO] Running com.johnmanko.service.data.HelloEndpointResourceIT
[WARNING] Tests run: 1, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.003 s -- in com.johnmanko.service.data.HelloEndpointResourceIT
[INFO] 
[INFO] Results:
[INFO] 
[ERROR] Errors: 
[ERROR]   DataEndpointResourceIT.postLock » Runtime java.lang.IllegalStateException: Unable to determine the status of the running process. See the above logs for details
[INFO] 
[ERROR] Tests run: 2, Failures: 0, Errors: 1, Skipped: 1
[INFO] 
[INFO] 
[INFO] --- failsafe:3.2.5:verify (default) @ quarkus-redis-service-example ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  02:20 min
[INFO] Finished at: 2024-05-22T17:01:46-04:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-failsafe-plugin:3.2.5:verify (default) on project quarkus-redis-service-example: 
[ERROR] 
[ERROR] Please refer to /path/to/projects/github/quarkus-redis-service-example/target/failsafe-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
    
❯ more ./target/quarkus.log                                                                                                                                                                                
Redis host not configured - you must either configure 'quarkus.redis.hosts` or 'quarkus.redis.host-provider-name' and have a bean providing the hosts programmatically.                                    
java.lang.RuntimeException: Failed to start quarkus                                                                                                                                                        
        at io.quarkus.runner.ApplicationImpl.doStart(Unknown Source)
        at io.quarkus.runtime.Application.start(Application.java:101)
        at io.quarkus.runtime.ApplicationLifecycleManager.run(ApplicationLifecycleManager.java:111)
        at io.quarkus.runtime.Quarkus.run(Quarkus.java:71)
        at io.quarkus.runtime.Quarkus.run(Quarkus.java:44)
        at io.quarkus.runtime.Quarkus.run(Quarkus.java:124)
        at io.quarkus.runner.GeneratedMain.main(Unknown Source)
Caused by: io.quarkus.runtime.configuration.ConfigurationException: Redis host not configured - you must either configure 'quarkus.redis.hosts` or 'quarkus.redis.host-provider-name' and have a bean provi
ding the hosts programmatically.
        at io.quarkus.redis.runtime.client.VertxRedisClientFactory.create(VertxRedisClientFactory.java:61)
        at io.quarkus.redis.runtime.client.RedisClientRecorder.lambda$_initialize$1(RedisClientRecorder.java:96)
        at java.base@21.0.3/java.util.HashMap.computeIfAbsent(HashMap.java:1228)
        at io.quarkus.redis.runtime.client.RedisClientRecorder._initialize(RedisClientRecorder.java:94)
        at io.quarkus.redis.runtime.client.RedisClientRecorder.initialize(RedisClientRecorder.java:63)
        at io.quarkus.deployment.steps.RedisDatasourceProcessor$init1511358714.deploy_0(Unknown Source)
        at io.quarkus.deployment.steps.RedisDatasourceProcessor$init1511358714.deploy(Unknown Source)
        ... 7 more

Expected behavior

I would expect that a Redis instance would started and quarkus.redis.hosts set accordingly for the integration tests.

Actual behavior

Is fails on ITs.

How to Reproduce?

  1. Grab project with exact code/config I was testing with: https://github.com/johnmanko/quarkus-redis-service-example

  2. Run: ./mvnw verify -Dnative -Dquarkus.container-image.build=true

Output of uname -a or ver

6.5.0-35-generic

Output of java -version

openjdk version "22-ea" 2024-03-19

Mandrel or GraalVM version (if different from Java)

No response

Quarkus version or git rev

3.10.2

Build tool (ie. output of mvnw --version or gradlew --version)

Apache Maven 3.9.6

Additional information

No response

@johnmanko johnmanko added area/native-image kind/bug Something isn't working labels May 22, 2024
@quarkus-bot
Copy link

quarkus-bot bot commented May 22, 2024

/cc @Karm (mandrel), @galderz (mandrel), @zakkak (mandrel)

@johnmanko johnmanko changed the title During IT: Could not attach to network: Not Found During IT: Redis host not configured May 22, 2024
@geoand
Copy link
Contributor

geoand commented May 23, 2024

I cannot reproduce this on my machine

@johnmanko
Copy link
Author

@geoand Not even with the sample project I provided?

https://github.com/johnmanko/quarkus-redis-service-example

I made sure to quarkus update, but it's still failing for me.

@geoand
Copy link
Contributor

geoand commented May 23, 2024

Yes, that's the project I tried

@galderz
Copy link
Member

galderz commented Jun 3, 2024

I cannot reproduce this on my machine

Neither can I reproduce. Tried on a mac, so needed to add -Dquarkus.native.container-build=true so that native was built inside a linux container to be usable by the container that runs the native binary. My test output:

[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running com.johnmanko.service.data.DataEndpointResourceIT
2024-06-03 15:26:46,881 INFO  [org.tes.doc.DockerClientProviderStrategy] (build-4) Loaded org.testcontainers.dockerclient.UnixSocketClientProviderStrategy from ~/.testcontainers.properties, will try it first
2024-06-03 15:26:47,041 INFO  [org.tes.doc.DockerClientProviderStrategy] (build-4) Found Docker environment with local Unix socket (unix:///var/run/docker.sock)
2024-06-03 15:26:47,042 INFO  [org.tes.DockerClientFactory] (build-4) Docker host IP address is localhost
2024-06-03 15:26:47,080 INFO  [org.tes.DockerClientFactory] (build-4) Connected to docker:
  Server Version: 4.9.3
  API Version: 1.41
  Operating System: fedora
  Total Memory: 7360 MB
2024-06-03 15:26:47,088 INFO  [org.tes.ima.PullPolicy] (build-4) Image pull policy will be performed by: DefaultPullPolicy()
2024-06-03 15:26:47,088 INFO  [org.tes.uti.ImageNameSubstitutor] (build-4) Image name substitution will be performed by: DefaultImageNameSubstitutor (composite of 'ConfigurationFileImageNameSubstitutor' and 'PrefixingImageNameSubstitutor')
2024-06-03 15:26:47,091 INFO  [org.tes.DockerClientFactory] (build-4) Checking the system...
2024-06-03 15:26:47,091 INFO  [org.tes.DockerClientFactory] (build-4) ✔︎ Docker server version should be at least 1.6.0
2024-06-03 15:26:47,129 INFO  [tc.doc.io/redis:7] (build-4) Creating container for image: docker.io/redis:7
2024-06-03 15:26:47,137 INFO  [tc.tes.6.0] (build-4) Creating container for image: testcontainers/ryuk:0.6.0
2024-06-03 15:26:47,176 INFO  [tc.tes.6.0] (build-4) Container testcontainers/ryuk:0.6.0 is starting: a19d15d4be2240b3d3f929d538e6dd88c6e82209622ec1a2e313ef4ab5e06aa8
2024-06-03 15:26:47,379 INFO  [tc.tes.6.0] (build-4) Container testcontainers/ryuk:0.6.0 started in PT0.242079S
2024-06-03 15:26:47,404 INFO  [tc.doc.io/redis:7] (build-4) Container docker.io/redis:7 is starting: 74686ab49d040f11430d9ffeeb1348eaf499e3fba535403600a0ab5d4ad668e7
2024-06-03 15:26:47,551 INFO  [tc.doc.io/redis:7] (build-4) Container docker.io/redis:7 started in PT0.422237S
2024-06-03 15:26:47,551 INFO  [io.qua.red.dep.cli.DevServicesRedisProcessor] (build-4) The <default> redis server is ready to accept connections on redis://redis-jpgf9:6379
2024-06-03 15:26:48,159 INFO  [io.qua.tes.com.DefaultDockerContainerLauncher] (main) Executing "podman run --name quarkus-integration-test-BMefa -i --rm -p 8081:8081 -p 8444:8444 --net=c0f9b9f1b4e287986c69258db972694170f3291645737288c5f914bc43065e3e --env QUARKUS_LOG_CATEGORY__IO_QUARKUS__LEVEL=INFO --env QUARKUS_HTTP_PORT=8081 --env QUARKUS_HTTP_SSL_PORT=8444 --env TEST_URL=http://localhost:8081 --env QUARKUS_REDIS_HOSTS=redis://redis-jpgf9:6379 --env QUARKUS_CONTAINER_IMAGE_BUILD=true --env QUARKUS_NATIVE_CONTAINER_BUILD=true galder/quarkus-redis-service-example:1.0.0-SNAPSHOT"
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 3.249 s -- in com.johnmanko.service.data.DataEndpointResourceIT
[INFO] Running com.johnmanko.service.data.HelloEndpointResourceIT
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.014 s -- in com.johnmanko.service.data.HelloEndpointResourceIT
[INFO]
[INFO] Results:
[INFO]
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0

@zakkak
Copy link
Contributor

zakkak commented Jun 4, 2024

@johnmanko, according to:

2024-05-22 17:00:45,790 ERROR [org.tes.doc.DockerClientProviderStrategy] (main) Could not find a valid Docker environment. Please check configuration. Attempted configurations were:
As no valid configuration was found, execution cannot continue.
See https://java.testcontainers.org/on_failure.html for more details.

There seems to be an issue with docker detection by TestContainers.

@johnmanko
Copy link
Author

@zakkak / @galderz

The only thing that works for me is removing the extension container-image-docker .

@zakkak
Copy link
Contributor

zakkak commented Jun 6, 2024

@johnmanko does it work without -Dnative?

@geoand geoand added the triage/needs-feedback We are waiting for feedback. label Jun 6, 2024
@johnmanko
Copy link
Author

@johnmanko does it work without -Dnative?

I'll try when I'm back in the office next week. I forget off-hand which options (don't) work as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/native-image kind/bug Something isn't working triage/needs-feedback We are waiting for feedback.
Projects
None yet
Development

No branches or pull requests

4 participants