Uploaded image for project: 'Quarkus'
  1. Quarkus
  2. QUARKUS-5184

Quarkus service fails to compile in native with fips and RH mandrel image

XMLWordPrintable

    • False
    • None
    • False
    • Hide

      Use a machine with JDK 21 + fips enabled + docker.

      Download & unzip CR1 repo - http://download.eng.bos.redhat.com/rcm-guest/staging/quarkus//quarkus-platform-3.15.1.CR1/rh-quarkus-platform-3.15.1.CR1-maven-repository.zip
      Clone repo - https://github.com/mocenas/quarkus-native-fips-reproducer
      Run the reproducer

      mvn clean verify -Dnative -Dquarkus.platform.version=3.15.1.redhat-00002 -Dquarkus.platform.group-id=com.redhat.quarkus.platform -Dmaven.repo.local=<path to unzipped repo>
      

      Bug is also reproducible with quarkus 3.15.1 community. To reproduce is in that case, just run the reproducer with:

      mvn clean verify -Dnative
      
      Show
      Use a machine with JDK 21 + fips enabled + docker. Download & unzip CR1 repo - http://download.eng.bos.redhat.com/rcm-guest/staging/quarkus//quarkus-platform-3.15.1.CR1/rh-quarkus-platform-3.15.1.CR1-maven-repository.zip Clone repo - https://github.com/mocenas/quarkus-native-fips-reproducer Run the reproducer mvn clean verify -Dnative -Dquarkus.platform.version=3.15.1.redhat-00002 -Dquarkus.platform.group-id=com.redhat.quarkus.platform -Dmaven.repo.local=<path to unzipped repo> Bug is also reproducible with quarkus 3.15.1 community. To reproduce is in that case, just run the reproducer with: mvn clean verify -Dnative
    • ---

      Running quarkus 3.15.1 in native with FIPS enabled and with RH mandrel image - "registry-proxy.engineering.redhat.com/rh-osbs/quarkus-mandrel-for-jdk-21-rhel8:23.1" causes quarkus services to fail in some cases.
      Failure is:

      Fatal error: org.graalvm.compiler.debug.GraalError: java.lang.NullPointerException: Cannot invoke "java.util.Set.iterator()" because "services" is null
      	at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.AnalysisFuture.setException(AnalysisFuture.java:49)
      	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:322)
      	at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.AnalysisFuture.ensureDone(AnalysisFuture.java:63)
      	at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.meta.AnalysisElement.lambda$execute$2(AnalysisElement.java:220)
      	at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.CompletionExecutor.executeCommand(CompletionExecutor.java:187)
      	at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.CompletionExecutor.lambda$executeService$0(CompletionExecutor.java:171)
      	at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1423)
      	at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:387)
      	at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1312)
      	at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1843)
      	at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1808)
      	at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:188)
      Caused by: java.lang.NullPointerException: Cannot invoke "java.util.Set.iterator()" because "services" is null
      	at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.SecurityServicesFeature.doRegisterServices(SecurityServicesFeature.java:798)
      	at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.SecurityServicesFeature.lambda$registerServices$17(SecurityServicesFeature.java:789)
      	at java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1740)
      	at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.SecurityServicesFeature.registerServices(SecurityServicesFeature.java:788)
      	at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.SecurityServicesFeature.registerServices(SecurityServicesFeature.java:766)
      	at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.SecurityServicesFeature.lambda$registerSASLReachabilityHandlers$12(SecurityServicesFeature.java:699)
      	at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.meta.AnalysisElement$ElementNotification.lambda$notifyCallback$0(AnalysisElement.java:147)
      	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
      	... 10 more
      

      This occurs only is quarkus apps that use some service (e.g. MariaDbService) for testing, but not for all of the apps. I didn't find exact condition that triggers this exception, but it affects a lot of apps in testsuite. Extracted one such configuration into reproducer: https://github.com/mocenas/quarkus-native-fips-reproducer

      Some points about this bug

      • Only happens on FIPS
      • Only happens with RH mandrel image
      • Affects both RHBQ and community quarkus 3.15.1 builds.

              rh-ee-galder Galder Zamarreño
              mocenas@redhat.com Martin Ocenas
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: