Application Scenario When Web projects such as Springboot of Eclipse and IDEA are packaged, Java2D graphical interfaces or components such as AWT or Swing cannot run
Cause This warning is caused by the fact that the Swing-based CanvasFrame window cannot be used because Maven packaging does not enter java.awt.headless by default.
Headless =false or -djava.awt. headless=false