Quarkus Camel Build在Kubernetes上失败

发布于 2025-02-03 08:47:25 字数 7447 浏览 3 评论 0原文

我有一个使用Quarkus,骆驼的项目,该项目在本地构建良好,但是当我尝试在CI环境(通过我的Jenkins环境或Bitbucket上)构建它时,我会遇到奇怪的失败。但是,我无法真正跟踪源头,并且对可能导致这一点的原因感到非常困惑。我的kubernetes存储没有启用任何可读标志。 这仅在kubernetes中不仅在docker容器内部都在本地开始


[INFO] Building jar: /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/gateway-service-starter-1.5.1.jar
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:build (default) @ gateway-service-starter ---
[INFO] No Git Properties File Url Defined. Attempting with default: git.properties
[ERROR] Unable to load default git properties file git.properties
[INFO] [io.quarkus.deployment.QuarkusAugmentor] Quarkus augmentation completed in 10087ms
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ gateway-service-starter ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:generate-code (default) @ gateway-service-starter ---
[INFO] 
[INFO] --- maven-compiler-plugin:3.10.1:compile (default-compile) @ gateway-service-starter ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 54 source files to /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/classes
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:generate-code-tests (default) @ gateway-service-starter ---
[INFO] 
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ gateway-service-starter ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.10.1:testCompile (default-testCompile) @ gateway-service-starter ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 22 source files to /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/test-classes
[INFO] 
[INFO] --- maven-surefire-plugin:3.0.0-M6:test (default-test) @ gateway-service-starter ---
[INFO] Skipping execution of surefire because it has already been run for this configuration
[INFO] 
[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ gateway-service-starter ---
[INFO] Building jar: /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/gateway-service-starter-1.5.1.jar
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:build (default) @ gateway-service-starter ---
[INFO] No Git Properties File Url Defined. Attempting with default: git.properties
[ERROR] Unable to load default git properties file git.properties
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  02:14 min
[INFO] Finished at: 2022-05-30T13:34:00Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:2.9.0.CR1:build (default) on project gateway-service-starter: Failed to build quarkus application: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
[ERROR]     [error]: Build step org.apache.camel.quarkus.core.deployment.CamelNativeImageProcessor#camelRuntimeCatalog threw an exception: java.nio.file.ClosedFileSystemException
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.ensureOpen(ZipFileSystem.java:1619)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.getFileAttributes(ZipFileSystem.java:531)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:767)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:777)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystemProvider.readAttributes(ZipFileSystemProvider.java:276)
[ERROR]     at java.base/java.nio.file.Files.readAttributes(Files.java:1851)
[ERROR]     at java.base/java.nio.file.Files.isDirectory(Files.java:2322)
[ERROR]     at org.apache.camel.quarkus.core.deployment.util.CamelSupport.services(CamelSupport.java:71)
[ERROR]     at org.apache.camel.quarkus.core.deployment.CamelNativeImageProcessor.camelRuntimeCatalog(CamelNativeImageProcessor.java:170)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
[ERROR]     at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR]     at java.base/java.lang.reflect.Method.invoke(Method.java:568)
[ERROR]     at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:925)
[ERROR]     at io.quarkus.builder.BuildContext.run(BuildContext.java:277)
[ERROR]     at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
[ERROR]     at java.base/java.lang.Thread.run(Thread.java:833)
[ERROR]     at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[ERROR] 
[ERROR]     [error]: Build step org.apache.camel.quarkus.core.deployment.CamelProcessor#camelServices threw an exception: java.nio.file.ClosedFileSystemException
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.ensureOpen(ZipFileSystem.java:1619)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.getFileAttributes(ZipFileSystem.java:531)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:767)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:777)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystemProvider.readAttributes(ZipFileSystemProvider.java:276)
[ERROR]     at java.base/java.nio.file.Files.readAttributes(Files.java:1851)
[ERROR]     at java.base/java.nio.file.Files.isDirectory(Files.java:2322)
[ERROR]     at org.apache.camel.quarkus.core.deployment.util.CamelSupport.services(CamelSupport.java:71)
[ERROR]     at org.apache.camel.quarkus.core.deployment.CamelProcessor.camelServices(CamelProcessor.java:213)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
[ERROR]     at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR]     at java.base/java.lang.reflect.Method.invoke(Method.java:568)
[ERROR]     at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:925)
[ERROR]     at io.quarkus.builder.BuildContext.run(BuildContext.java:277)
[ERROR]     at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
[ERROR]     at java.base/java.lang.Thread.run(Thread.java:833)
[ERROR]     at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[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/MojoExecutionException

I have a project using quarkus, camel which builds fine locally however when i try to build it on my CI environment (either through my jenkins environment or on bitbucket) I get a weird failure. I can't really track the source however and am quite stumped as to what can be causing this. My kubernetes storage does not have any readonly flags enabled.
This fails only in kubernetes not even inside just a docker container started locally


[INFO] Building jar: /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/gateway-service-starter-1.5.1.jar
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:build (default) @ gateway-service-starter ---
[INFO] No Git Properties File Url Defined. Attempting with default: git.properties
[ERROR] Unable to load default git properties file git.properties
[INFO] [io.quarkus.deployment.QuarkusAugmentor] Quarkus augmentation completed in 10087ms
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ gateway-service-starter ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:generate-code (default) @ gateway-service-starter ---
[INFO] 
[INFO] --- maven-compiler-plugin:3.10.1:compile (default-compile) @ gateway-service-starter ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 54 source files to /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/classes
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:generate-code-tests (default) @ gateway-service-starter ---
[INFO] 
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ gateway-service-starter ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.10.1:testCompile (default-testCompile) @ gateway-service-starter ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 22 source files to /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/test-classes
[INFO] 
[INFO] --- maven-surefire-plugin:3.0.0-M6:test (default-test) @ gateway-service-starter ---
[INFO] Skipping execution of surefire because it has already been run for this configuration
[INFO] 
[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ gateway-service-starter ---
[INFO] Building jar: /home/jenkins/agent/workspace/Build Jobs/Build Gateway Service Starter/target/gateway-service-starter-1.5.1.jar
[INFO] 
[INFO] --- quarkus-maven-plugin:2.9.0.CR1:build (default) @ gateway-service-starter ---
[INFO] No Git Properties File Url Defined. Attempting with default: git.properties
[ERROR] Unable to load default git properties file git.properties
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  02:14 min
[INFO] Finished at: 2022-05-30T13:34:00Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:2.9.0.CR1:build (default) on project gateway-service-starter: Failed to build quarkus application: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
[ERROR]     [error]: Build step org.apache.camel.quarkus.core.deployment.CamelNativeImageProcessor#camelRuntimeCatalog threw an exception: java.nio.file.ClosedFileSystemException
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.ensureOpen(ZipFileSystem.java:1619)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.getFileAttributes(ZipFileSystem.java:531)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:767)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:777)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystemProvider.readAttributes(ZipFileSystemProvider.java:276)
[ERROR]     at java.base/java.nio.file.Files.readAttributes(Files.java:1851)
[ERROR]     at java.base/java.nio.file.Files.isDirectory(Files.java:2322)
[ERROR]     at org.apache.camel.quarkus.core.deployment.util.CamelSupport.services(CamelSupport.java:71)
[ERROR]     at org.apache.camel.quarkus.core.deployment.CamelNativeImageProcessor.camelRuntimeCatalog(CamelNativeImageProcessor.java:170)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
[ERROR]     at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR]     at java.base/java.lang.reflect.Method.invoke(Method.java:568)
[ERROR]     at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:925)
[ERROR]     at io.quarkus.builder.BuildContext.run(BuildContext.java:277)
[ERROR]     at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
[ERROR]     at java.base/java.lang.Thread.run(Thread.java:833)
[ERROR]     at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[ERROR] 
[ERROR]     [error]: Build step org.apache.camel.quarkus.core.deployment.CamelProcessor#camelServices threw an exception: java.nio.file.ClosedFileSystemException
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.ensureOpen(ZipFileSystem.java:1619)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystem.getFileAttributes(ZipFileSystem.java:531)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:767)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipPath.readAttributes(ZipPath.java:777)
[ERROR]     at jdk.zipfs/jdk.nio.zipfs.ZipFileSystemProvider.readAttributes(ZipFileSystemProvider.java:276)
[ERROR]     at java.base/java.nio.file.Files.readAttributes(Files.java:1851)
[ERROR]     at java.base/java.nio.file.Files.isDirectory(Files.java:2322)
[ERROR]     at org.apache.camel.quarkus.core.deployment.util.CamelSupport.services(CamelSupport.java:71)
[ERROR]     at org.apache.camel.quarkus.core.deployment.CamelProcessor.camelServices(CamelProcessor.java:213)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR]     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
[ERROR]     at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR]     at java.base/java.lang.reflect.Method.invoke(Method.java:568)
[ERROR]     at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:925)
[ERROR]     at io.quarkus.builder.BuildContext.run(BuildContext.java:277)
[ERROR]     at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
[ERROR]     at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
[ERROR]     at java.base/java.lang.Thread.run(Thread.java:833)
[ERROR]     at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[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/MojoExecutionException

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

难理解 2025-02-10 08:47:25

奇怪的是,我们的解决方案是使用MVN CLEAN INSTALL而不是MVN Clean Clean验证验证程序包

理论上不应该有所作为,但确实如此。

Weirdly, the solution for us was to use mvn clean install rather than mvn clean verify package

Theoretically, shouldn't make the difference but it did.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文