devinbost opened a new issue #10039:
URL: https://github.com/apache/pulsar/issues/10039


   When attempting to run Pulsar tests in IntelliJ, I was getting this error:
   
   ```
   Unrecognized option: --add-opens
   Error: Could not create the Java Virtual Machine.
   Error: A fatal exception has occurred. Program will exit.
   ```
   I verified that the project was set to use JDK 1.8. 
   
   What I discovered was that in the Maven settings in IntelliJ, the "JDK for 
importer" was set to use JRE 11. 
   After changing this value, I noticed that immediately after running Reload 
All Maven Projects from the Maven sidebar, I was given this pop-up:
   ![Screen Shot 2021-03-25 at 12 47 40 
AM](https://user-images.githubusercontent.com/7418031/112431227-db167600-8d04-11eb-9b45-e32b6b2d0fea.png)
   
   If I click on "Load Maven Project", it immediately breaks my ability to run 
tests from the IDE because it reverts the "JDK for importer" setting back to 
JRE 11. After clicking "Skip," the project loaded correctly, and I was able to 
actually run tests from the IDE. 
   I'm not sure what this "build script" is that Maven reportedly found, but it 
seems to be causing problems. 
   
   I'm running:
   
   > IntelliJ IDEA 2020.3.3 (Community Edition)
   > Build #IC-203.7717.56, built on March 15, 2021
   > Runtime version: 11.0.10+8-b1145.96 x86_64
   > VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
   > macOS 10.15.7
   > GC: ParNew, ConcurrentMarkSweep
   > Non-Bundled Plugins: Statistic, zielu.gittoolbox, com.thoughtworks.gauge, 
org.intellij.scala, com.madrapps.dagger-plugin
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to