I am using VS Code to edit and run Android projects. The emulator will open and I see the program OpenJDK Platform binary
start, followed by the program compiling and running. However, after closing the Android emulator and VS Code, OpenJDK continues to run.
(Task manager after closing Emulator/VSC)
Is this normal behavior? Is there a way to have OpenJDK JRE shut down after the emulator/VSC exits?
My main concern is battery life as I am using a laptop.
System: Windows 10 Pro (1909)
Visual Studio Code version: 1.42.0
1* open the task manager, and locate the process ID
2*
TASKKILL /PID %PID%
The JVM Process Status Tool helped me identify why OpenJDK was not closing. Running [path_to_jre]/bin/jps -l
in terminal spat out the following:
2272 org.gradle.launcher.daemon.bootstrap.GradleDaemon
4500 sun.tools.jps.Jps
...
{
"label": "gradle --stop",
"type": "shell",
"command": "C:\\Gradle\\gradle-6.1.1\\bin\\gradle --stop",
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "shared",
"showReuseMessage": true,
"clear": false
},
"problemMatcher": []
},
...
This results in the OpenJDK process ending.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.