Re: java.lang.ClassNotFoundException: com.google.common.base.Preconditions

2022-07-24 Thread Siddharth Jain
could you explain this to me? we have tried running without configuring any agent mvn exec:java -X -Dexec.mainClass=com.example.App and the exception is still there. and maven:exec works for other projects. On Sun, Jul 24, 2022 at 1:19 PM Bernd Eckenfels wrote: > Since exec:java executes in the

Re: java.lang.ClassNotFoundException: com.google.common.base.Preconditions

2022-07-24 Thread Bernd Eckenfels
Since exec:java executes in the running JVM it does not reconfigure the (boot)classpath but provides a configured classloader. It looks like the measuring agent does not like that. In that Case you need either exec:exec or a plug-in for that purpose. Gruss Bernd -- http://bernd.eckenfels.net

Re: java.lang.ClassNotFoundException: com.google.common.base.Preconditions

2022-07-24 Thread Thomas Broyer
IIRC exec:java doesn't fork a new JVM so the java.class.path is the one from Maven itself. Your dependencies are "only" in a custom classloader. You might want to try exec:exec with java as the executable. Le dim. 24 juil. 2022 à 20:46, Siddharth Jain a écrit : > we are running into the dreaded

java.lang.ClassNotFoundException: com.google.common.base.Preconditions

2022-07-24 Thread Siddharth Jain
we are running into the dreaded ClassNotFoundException in a project. Here is the setup. Using JDK 11 and Maven 3.8.5. Trying to create sample test project that uses memory-measurer to measure memory. First we mvn packaged and installed the memory