This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes JBoss/WildFly and the fly likes Two JVM's on a single Jboss Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Products » JBoss/WildFly
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
Marshal

Joined: Jul 20, 2005
Posts: 9317
    
109

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
Marshal

Joined: Jul 20, 2005
Posts: 9317
    
109

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
Marshal

Joined: Jul 20, 2005
Posts: 9317
    
109

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 ...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Two JVM's on a single Jboss
 
Similar Threads
More than one servlet per web application
Multiple JVMs (default vs. non-default servlet context)
What is the difference between ServletContext and ServletConfig
ServletContext in the clustered environment
Servlet Context vs Application Context