Interview Question: What is the difference between EAR, JAR and WAR file?

By: Ash  

Question:What is the difference between EAR, JAR and WAR file?


J2EE defines three types of archives:

1. Java Archives (JAR) A JAR file encapsulates one or more Java classes, a manifest, and a descriptor. JAR files are the lowest level of archive. JAR files are used in J2EE for packaging EJBs and client-side Java Applications.

2. Web Archives (WAR) WAR files are similar to JAR files, except that they are specifically for web applications made from Servlets, JSPs, and supporting classes.

3. Enterprise Archives (EAR) ”An EAR file contains all of the components that make up a particular J2EE application.





Archived Comments

1. aviscu3
View Tutorial          By: virgilvn3 at 2017-05-15 15:10:18

Most Viewed Articles (in Interview )

How to define an Interface?

Question: What is a Hidden Comment in JSP?

What is the difference between jsp:forward and response.sendRedirect(url),?.

Interview Question: What are the call back methods in Entity bean?

Interview Question: What is Message Driven Bean?

Is Iterator a Class or Interface? What is its use?

Interview Question: What is the difference between JavaBean and EJB?

Differentiate between .ear, .jar and .war files.

Interview Question: Can i map more than one table in a CMP?

Interview Question: What is difference between EJB 1.1 and EJB 2.0?

Question: What is the directory structure of a web application?

Question: Explain the life-cycle methods in JSP?

What types of comments are available in the JSP?

Interview Question: How does Struts work?

What is difference between Java Bean and Enterprise Java Bean?

Latest Articles (in Interview)

Comment on this tutorial