• Post Reply Bookmark Topic Watch Topic
  • New Topic

JVM , App Server understanding  RSS feed

 
Saxena Sajal
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have heard so many times some architectures like one cluster have four server then one server has 4 JVMs.
And even people judge which app need to run on which JVM.
What i understand is that an application is hosted on an application server so how only one JVM comes into picture.
What exactly is the relation of JVMs with the server and what is the role of a JVM.

It always makes me confuse, Someone please elaborate this.
 
Anayonkar Shivalkar
Bartender
Posts: 1558
5
Eclipse IDE Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sajal,

Welcome to CodeRanch!

The concept is not very difficult to understand: Whenever you start an application with 'java' command (directly or indirectly), then you are starting a JVM.
e.g. you write a simple 'addition' program and if you run it 5 times - it will spawn 5 different processes, and each process is a JVM.

A cluster is set of application server processes. A cluster can be created on single host (which is not preferred) or multiple host (which is preferred).

Coming to server - I'm not clear what do you mean by 'server' - is it physical host, or application server? An application server works with single JVM.

Now, since you can have different configuration for different JVMs, it is logical to execute applications (mostly JSE) across different JVMs.

To summarize:
1 Cluster: 1 or more application server
1 Application server: 1 JVM
1 Java instance: 1 JVM

You can have multiple applications on single application server - in which case, all those apps would run in single JVM instance (and we have to be careful while dealing with singleton objects etc.)

I hope this helps.
 
Saxena Sajal
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Anayonkar Shivalkar wrote:Hi Sajal,

Welcome to CodeRanch!

The concept is not very difficult to understand: Whenever you start an application with 'java' command (directly or indirectly), then you are starting a JVM.
e.g. you write a simple 'addition' program and if you run it 5 times - it will spawn 5 different processes, and each process is a JVM.

A cluster is set of application server processes. A cluster can be created on single host (which is not preferred) or multiple host (which is preferred).

Coming to server - I'm not clear what do you mean by 'server' - is it physical host, or application server? An application server works with single JVM.

Now, since you can have different configuration for different JVMs, it is logical to execute applications (mostly JSE) across different JVMs.

To summarize:
1 Cluster: 1 or more application server
1 Application server: 1 JVM
1 Java instance: 1 JVM

You can have multiple applications on single application server - in which case, all those apps would run in single JVM instance (and we have to be careful while dealing with singleton objects etc.)

I hope this helps.


Thanks for the reply.
Can we add mutiple application servers in a single websphere application server console. I have a structure where in a cluster four physical servers exists.
and each physical server has 6 JVMs. Does that mean on one physical server there are 6 application servers and each application server is associated with a JVM?

And this whole configuration can be seen from just one websphere application server console?
 
Anayonkar Shivalkar
Bartender
Posts: 1558
5
Eclipse IDE Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
WAS(Websphere Application Server) console is just a way to manage server configuration. Technically, we don't add server instances 'in' the console, but we do it 'via' console.

I assume by 'physical server', you mean to say 'host'. So, yes, it is possible to have a single cluster with 4 hosts and 6 JVMs each. Thus, we are having total 24 instance of WAS. And this configuration can be seen and changed (to change, you need to have proper access rights) via WAS console.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!