Is there one JVM per Java application?

前端 未结 8 1627
被撕碎了的回忆
被撕碎了的回忆 2020-11-28 18:52

Is the same JVM used by all Java applications running or, does \'one JVM per Java application\' apply? (say the applications are IntelliJ IDEA, a server and NetBeans for exa

8条回答
  •  南方客
    南方客 (楼主)
    2020-11-28 19:18

    There's one JVM per Java application. There shouldn't be any connection between them unless you establish one, e.g. with networking. If you're working inside of an IDE, the code you write generally runs in a separate JVM. The IDE will typically connect the separate JVM for debugging. If you're dealing with multiple web applications they could share the same JVM if they're deployed to the same web container.

提交回复
热议问题