• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JVM and JRE

 
Jitendra Kumar
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Recently I was asked about the differences between JRE and JVM in an interview. All this while I thought I was pretty much aware of it, but I didn't had a proper technical answer to it.

Any technical and important differences that any one can share ??
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Pie
Posts: 15150
31
Android IntelliJ IDE Java Scala Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So what did you answer yourself?

The JVM and the JRE are two different things. You could compare it to a car. The JVM is the engine that interprets and executes Java bytecode.

But like with a car, if you want to go somewhere, you need more than just an engine. You also need a chassis, wheels, a steering wheel, etc.

The JVM is the engine and the JRE is the complete car - the engine plus all the things around it that you need to run Java programs.
 
Jitendra Kumar
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Jesper,

i also answered almost what you answered. Your analogy was good, but i was looking for some technical differences. What is chassis, steering etc in JRE ? I have read both JVM and JRE being used synonimously at a lot of places.

What do other members think about this.
 
Ulf Dittmer
Rancher
Pie
Posts: 42966
73
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Most important amongst the extra bits of the JRE are probably the class libraries. Smaller ones would be the Java Web Start and Java Plugin components:

[ August 04, 2006: Message edited by: Ulf Dittmer ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic