Apache Maven
Beginner to Guru
Review of Java Compile and Packaging
Java Compile Process
Source Files Java Complier Class Files The JVM Runtime
[Link] [Link]
[Link] [Link]
[Link] [Link]
[Link] [Link]
Packaging Java Applications
Many Class Files Zip Compression *.jar, *.war, *.ear Unzip JVM
[Link]
[Link]
[Link]
[Link]
Java Packaging
• *.jar - Java ARchive - Zip file containing one or more Java class files.
• *.war - Web Application aRchive - Zip file containing web application. Includes one or more jar
files, Java class files, and web resources.
• *.ear - Enterprise aRchive - Zip file containing one more more WAR files.
• Fat JAR (aka Uber JAR) - Executable Jar containing all dependencies. (Used by Spring Boot)
• Docker Container - Docker Image containing runtime environment, JVM, and Java package
Java Deployment
• Simple JAR files are typically collection of class files used to compose applications
• Typically not a complete application
• WAR, EAR files are typically complete applications which are deployed to application servers
• Tomcat / Weboss, Websphere, etc
• Fat / Uber Jars are typically complete applications which contain embedded application servers
• Can be deployed stand alone
• Docker Images are complete applications which can be deployed stand alone
Apache Maven
Beginner to Guru