Java Development process at a glance

The processes involved between the moment you write a program to the moment you execute it, is not as straightforward as one would expect. Here, in this post, we will try unwinding it a little bit.

Suppose you wrote some java program say, JCombat.java, which means that it if it contains any public class, the name of the class would definitely be, JCombat.

Okay, now the following steps are involved to make a java program finally run:


  1. There is a java compiler, javac,  that converts the java source code into something called Bytecode, into files having the extensions as ‘.class‘.
  2. To make sure that the java compiler and java commands are properly accessible, you need to set the environment variable ‘JAVA_HOME‘, by navigating to the ‘Advanced system settings‘ from your computer as shown:

Setting the JAVA_HOME

  1. Different JVM (Java Virtual Machine) are available for different platforms, like Windows, Linux, Mac and so on. Each of these JVM take the very same class file containing the bytecodes as the input.
  2. JVM could convert these bytecodes to the machine specific code, but it won’t, since the process would be extensively slower. The option to dynamically compile only the code segment that needs to run would be a wonderful idea and it is.
  3. This is exactly when the JIT Compiler (just-in-time compiler) comes into the picture next and compiles the needed bytecodes to the platform specific executable code or the native code.
  4. JIT Compiler runs on the user’s machine and is transparent to the user. Eventually, this is how a java code finally executes.

Trying to put this into some diagrammatic notation:

Java Development Stages

Kindly post in your queries as comments to this post.

Receive our updates to your inbox

Get more stuff like this
in your inbox

Subscribe to our mailing list and get interesting stuff and updates to your email inbox.