What is java.awt.headless ?
As well detailed in the article below,
Java contains a lot of classes which assume that there is a some sort of display and a keyboard attached. Sometimes, you are writing code to run on a server which does not have these and this is called Headless mode
For some Java-based web applications, graphics can be generated. Either you need to configure the application to use the local X Window server or use the Java Headless option.
Use case example for headless image processing : https://github.com/processing/processing/wiki/Running-without-a-Display