Whenever we start a Java program:
java Herpyl.java -derp
Is this creating another JVM instance, or another Java process on top of the same JVM instance? I'm confused as to the relationship between JVM and "Java" or a "Java process". Thanks in advance!
Each java invocation starts its own JVM.
Sharing one JVM between processes has problems wrt security and stability: If one process kills the JVM you also killed the other and the other process really shouldn't be able to read/modify the data of the other process without the right rights (don't forget you can call arbitrary JNI code from your java process).
If you're worried about memory consumption: Yes that does indeed increase the memory, but any modern OS will map different dlls and other things - on my win7 x64 machine an idle javaw process has a private workingset of ~300kb.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With