Skip to content

Unable to build application as "mutable-jar" using gradle plugin #34652

@esorio

Description

@esorio

Describe the bug

Hi,
If I build a project using the command ./gradlew build -Dquarkus.package.type=mutable-jar then I can perform the augmentation with java -jar -Dquarkus.launch.rebuild=true build/quarkus-app/quarkus-run.jar

Instead, if I configure the mutable-jar option inside the build.gradle (as stated in the doc)

quarkus {
   properties {
       set("package.type", "mutable-jar")  
   }
}

and compile with ./gradlew build then I can't perform the augmentation.

Expected behavior

The augmentation process completes.

Actual behavior

The augmentation fails with the following error.

Exception in thread "main" java.nio.file.NoSuchFileException: /home/esorio/Code/gradle-augmentation/build/quarkus-app/lib/deployment/deployment-class-path.dat
	at java.base/sun.nio.fs.UnixException.translateToIOException(UnixException.java:92)
	at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111)
	at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:116)
	at java.base/sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:219)
	at java.base/java.nio.file.Files.newByteChannel(Files.java:371)
	at java.base/java.nio.file.Files.newByteChannel(Files.java:422)
	at java.base/java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:420)
	at java.base/java.nio.file.Files.newInputStream(Files.java:156)
	at io.quarkus.bootstrap.runner.QuarkusEntryPoint.doReaugment(QuarkusEntryPoint.java:72)
	at io.quarkus.bootstrap.runner.QuarkusEntryPoint.doRun(QuarkusEntryPoint.java:48)
	at io.quarkus.bootstrap.runner.QuarkusEntryPoint.main(QuarkusEntryPoint.java:32)

How to Reproduce?

No response

Output of uname -a or ver

Linux 5.4.0-153-generic #170-Ubuntu SMP Fri Jun 16 13:43:31 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

Output of java -version

openjdk version "11.0.15" 2022-04-19

GraalVM version (if different from Java)

No response

Quarkus version or git rev

3.2.0.Final

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

Gradle 8.1.1

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions