Packaging WAR, JAR modules into EAR using Maven Build Tool

Introduction Here we will see the process of packaging WAR, JAR modules into EAR file. EAR, also known as, Enterprise Archive, in which all files (.jar and .war) are packaged as JAR file with .ear (enterprise archive) extension and deployed into Application Server. WAR, JAR and EAR EJB modules which contain enterprise java beans (class files) and EJB deployment descriptor are packed as JAR files with .jar extenstion. Web modules which contain Servlet class files, JSP Files, supporting files, GIF and HTML files are packaged as JAR file with .war…

Continue

Spring Boot Multi-module Project

Introduction In this example we will see how to work with spring boot multi-module project and deploy them together in embedded Tomcat server. The Tomcat Server comes with the Spring Boot API, so we don’t need to include extra jar or library for it. The individual module is also deployable. You may also want to use other server like Jetty instead of Tomcat server in Spring Boot application. In this example we have three modules email-service – responsible for sending email to the specific email address, user-service – responsible for…

Continue

Creating Multi-Modules Maven Project in Eclipse

Introduction In this tutorial I will explain you how to create multi-modules maven project in Eclipse. This kind of project is a good design when you want to group similar applications or projects and reduce the duplication in code. A multi-module project is built from a parent pom that manages a group of submodules. In most cases, the parent pom is located in the project’s root directory and must have packaging of type pom. The submodules are regular maven projects and have packaging type different than pom, such as, jar,…

Continue