File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JBoss and the fly likes Two JVM's on a single Jboss Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Products » JBoss
Reply Bookmark "Two JVM Watch "Two JVM New topic
Author

Two JVM's on a single Jboss

karimkhan pathan
Ranch Hand

Joined: Jul 14, 2008
Posts: 86
There is one context per "web application" per Java Virtual Machine


As per servletcontext spec we will have one context per application per JVM.

My question is can we run find 2 JVM's on a single JBoss instance ?

If Yes then two servletContext will be present .


karim
Jaikiran Pai
Saloon Keeper

Joined: Jul 20, 2005
Posts: 6720

You can't have more than one JVM for one instance of JBoss AS. When you start a JBoss AS, a separate JVM is instantiated.

[My Blog] [JavaRanch Journal]
karimkhan pathan
Ranch Hand

Joined: Jul 14, 2008
Posts: 86
Jaikiran Pai wrote: When you start a JBoss AS, a separate JVM is instantiated.


Does this mean JBoss will have a separate JVM internally or it will use system default.
Jaikiran Pai
Saloon Keeper

Joined: Jul 20, 2005
Posts: 6720

Does this mean JBoss will have a separate JVM internally or it will use system default.

When you start the JBoss AS, the "java" command is executed (see the run.bat/run.sh script in the bin folder). The "java" command triggers the creation of a new JVM in which the AS will run.
karimkhan pathan
Ranch Hand

Joined: Jul 14, 2008
Posts: 86
Thanks for your quick replies .

This means that JBoss will start the System installed JVMm inn the classpath -Im i rite ?
Jaikiran Pai
Saloon Keeper

Joined: Jul 20, 2005
Posts: 6720

karimkhan pathan wrote:
This means that JBoss will start the System installed JVMm inn the classpath -Im i rite ?


It will use JAVA_HOME/bin/java to start the JVM. So whatever JVM you point to, through JAVA_HOME variable, will be used.


karimkhan pathan
Ranch Hand

Joined: Jul 14, 2008
Posts: 86
Thanks JaiKiran ..
It was helpful ...
 
 
subject: Two JVM's on a single Jboss
 
Threads others viewed
Servlet Context vs Application Context
ServletContext in the clustered environment
More than one servlet per web application
What is the difference between ServletContext and ServletConfig
Multiple JVMs (default vs. non-default servlet context)
IntelliJ Java IDE