Cannot transform *class as its containing application archive could not be found

See original GitHub issue

I have created an MCVE where I have the classic greeting resource and I’ve added a Utility class (private constructor w. one static method).

When using jacoco-extension the tests run just fine, but when adding quarkus-smallrye-openapi, dependency, I get these warnings when running tests:

[INFO] Running org.acme.testcoverage.UtilTest
2021-04-26 16:21:52,863 WARN  [io.qua.dep.ste.ClassTransformingBuildStep] (build-33) Cannot transform java.lang.Deprecated as its containing application archive could not be found.
2021-04-26 16:21:52,884 WARN  [io.qua.dep.ste.ClassTransformingBuildStep] (build-33) Cannot transform java.lang.Object as its containing application archive could not be found.
2021-04-26 16:21:52,885 WARN  [io.qua.dep.ste.ClassTransformingBuildStep] (build-33) Cannot transform jdk.internal.HotSpotIntrinsicCandidate as its containing application archive could not be found.
2021-04-26 16:21:52,897 WARN  [io.qua.dep.ste.ClassTransformingBuildStep] (build-33) Cannot transform java.util.Map as its containing application archive could not be found.
2021-04-26 16:21:52,898 WARN  [io.qua.dep.ste.ClassTransformingBuildStep] (build-33) Cannot transform java.lang.SafeVarargs as its containing application archive could not be found.
2021-04-26 16:21:52,928 WARN  [io.qua.dep.ste.ClassTransformingBuildStep] (build-33) Cannot transform java.util.Collection as its containing application archive could not be found.
2021-04-26 16:21:55,075 INFO  [io.quarkus] (main) Quarkus 1.13.2.Final on JVM started in 3.428s. Listening on: http://localhost:8081
2021-04-26 16:21:55,076 INFO  [io.quarkus] (main) Profile test activated. 
2021-04-26 16:21:55,076 INFO  [io.quarkus] (main) Installed features: [cdi, config-yaml, hibernate-validator, jacoco, jaeger, kubernetes-client, logging-gelf, resteasy, resteasy-jackson, smallrye-openapi, smallrye-opentracing, swagger-ui]
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 6.467 s - in org.acme.testcoverage.UtilTest
[INFO] Running org.acme.testcoverage.GreetingResourceTest
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.38 s - in org.acme.testcoverage.GreetingResourceTest
2021-04-26 16:21:57,005 INFO  [io.quarkus] (main) Quarkus stopped in 0.029s

Are the warnings valid (and thus I am misusing something)? ~Is such a utility class to be avoided in CDI?~
In our project, the warning is actually generated in non utility classes, as well.

To Reproduce

Steps to reproduce the behavior:

  1. git clone git@github.com:chris-asl/quarkus-jacoco-smallrye-openapi.git
  2. ./mvnw clean verify

Configuration

Defaults

Environment:

Output of uname -a or ver

Linux homer 5.8.0-48-generic #54~20.04.1-Ubuntu SMP Sat Mar 20 13:40:25 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

Output of java -version

openjdk version "11.0.10" 2021-01-19
OpenJDK Runtime Environment (build 11.0.10+9-Ubuntu-0ubuntu1.20.04)
OpenJDK 64-Bit Server VM (build 11.0.10+9-Ubuntu-0ubuntu1.20.04, mixed mode, sharing)

Quarkus version or git rev

1.13.2.Final

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

Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Maven home: /home/chris/.m2/wrapper/dists/apache-maven-3.6.3-bin/1iopthnavndlasol9gbrbg6bf2/apache-maven-3.6.3
Java version: 11.0.10, vendor: Ubuntu, runtime: /usr/lib/jvm/java-11-openjdk-amd64
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "5.8.0-48-generic", arch: "amd64", family: "unix"

FYI @el10686

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:11 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
phillip-krugercommented, Apr 29, 2021

Confirmed !! Thanks @stuartwdouglas . Fix and available in 1.13.3.Final

1reaction
geoandcommented, Apr 27, 2021

Thanks!

@phillip-kruger mind taking a look please?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Upgrade to 1.13.0.Final and above causes Cannot transform ...
Final and above causes Cannot transform java.util.concurrent.ThreadPoolExecutor as its containing application archive could not be found #18477.
Read more >
java - Maven test not running my `@QuarkusTest` with custom ...
I have another @QuarkusTest with no custom test profile. That runs well. It's a test profile defined as static class in the same...
Read more >
3 ways to solve java.lang.NoClassDefFoundError in Java J2EE
1) The class is not available in Java Classpath. ... In order to troubleshoot NoClassDefFoundError in the J2EE application knowledge of How ClassLoader ......
Read more >
Contexts and Dependency Injection - Quarkus
The bean archive is synthesized from: the application classes,. dependencies that contain a beans.xml descriptor (content is ignored),.
Read more >
Troubleshooting Bindings - Xamarin.Android - Microsoft Learn
Since the binding generator does not generate bindings for non-public classes, derived classes such as these cannot be generated correctly.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found