vscode-tomcat
                                
                                 vscode-tomcat copied to clipboard
                                
                                    vscode-tomcat copied to clipboard
                            
                            
                            
                        Can't select different JVM to run Tomcat instance
I can't select a different JVM to run instance of Apache Tomcat. Allways run with same JVM that VSCode.
I need to run Tomcat with JVM 1.7
I have the same problem as you. Seems it executes the "java" command directly to start tomcat instance in a process. There's no option to configure it. The only way is to change JVM environment variable external, which is annoying. Hope it can be fixed soon.... while it's 2020, there's no update yet.
You could pull down PR #277 an build it yourself
while #277 does help, I'd like to be able to select a specific JVM for tomcat separate from vscode-for-java extension. VSCode for Java requires java 11, but I want to run tomcat on java 8 for now.
You can set the java.home to a lower java version, but I don't think you will be abel to debugg anyway
You can set the java.home to a lower java version, but I don't think you will be abel to debugg anyway
No, I literally can't. Java Support for VSCode requires java 11, and it uses java.home to determine which JVM to use for itself.
IMO there should be a "tomcat.java.home" or similar property to determine the JVM for tomcat. It would also be useful when you want to test different JVMs(ie. OpenJ9 vs HotSpot, 11 vs 14, Amazon vs Oracle, etc) without changing the JVM used for the vscode-java extension.
edit:
Alternatively, adding a way to determine the JVM by java version (the java.configuration.runtimes property) instead of using java.home would be good.
Hi to all, I have the same problem. With the current configuration of the java runtimes "java.configuration.runtimes": [ { "name": "JavaSE-1.8", "path": "/usr/lib/jvm/jdk1.8.0_162", "default": true }, { "name": "JavaSE-11", "path": "/usr/lib/jvm/jdk-11.0.8", } ], "java.home": "/usr/lib/jvm/jdk-11.0.8",
I expected tomcat to use the DEFAULT jvm (jdk1.8.0_162), instead use java.home, but java.home needs 11 for the proper functioning of the vscode plugins.
How can I solve the problem?
Dario
I downgrade from 0.11.3 at 0.11.2 version and tomcat work correctly, now tomcat use the JDK 1.8 that I set as default=true.