>> How can I can find out EXACTLY how maven invoked javac, so I can >> invoke it the same way?
I think, somebody already mentioned earlier that you can just activate debug output in Maven. Then search for the line following "Command line options": $ mvn -X compile | grep --after-context 1 'Command line options' [DEBUG] Command line options: [DEBUG] -d ...\target\classes -classpath ... src\main\java\org\example\Main.java -s ... -processor ... -g -target 1.8 -source 1.8 -encoding UTF-8 Copy everything from the last line agter "[DEBUG] " and paste it right behind "javac ". That should be your exact command. > Okay, I think I got it. Here is the error I get when running with -J-Xmx800 > > <snip warnings about using internal APIs> > The system is out of resources. > Consult the following stack trace for details. > java.lang.OutOfMemoryError: GC overhead limit exceeded > <snip long stack trace from the depths of javac> Sorry to bother you again, but two more requests: 1. Can you please paste more of the stack trace? That would make for a good (as in realistic) unit or integration test. 2. I think, my PR in the recently released Plexus Compiler 2.14.2 should at least enable you to get the stack trace printed. The two header lines beginning with "The system is out of resources" probably will be cut off. Anyway, that would be better than nothing. Can you please retest? In Maven, that would go like this (fragmentary POM): <properties> <plexusCompilerVersion>2.14.2</plexusCompilerVersion> </properties> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.12.0</version> <dependencies> <dependency> <groupId>org.codehaus.plexus</groupId> <artifactId>plexus-compiler-api</artifactId> <version>${plexusCompilerVersion}</version> </dependency> <dependency> <groupId>org.codehaus.plexus</groupId> <artifactId>plexus-compiler-manager</artifactId> <version>${plexusCompilerVersion}</version> </dependency> <dependency> <groupId>org.codehaus.plexus</groupId> <artifactId>plexus-compiler-javac</artifactId> <version>${plexusCompilerVersion}</version> <scope>runtime</scope> </dependency> </dependencies> </plugin> -- Alexander Kriegisch https://scrum-master.de --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org