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?

Answer:

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.

 

 

 

 



Most Viewed Articles (in Interview )

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

How to define an Abstract class?

Explain the new Features of JDBC 2.0 Core API?

Interview Question: What is Local client view in EJB?

Interview Question: Is Decorator an EJB design pattern?

What are implicit Objects available to the JSP Page?

Interview Question: Can I invoke Runtime.gc() in an EJB?

Interview Question: What are the optional clauses in EJB QL?

Interview Question: Why does EJB needs two interfaces(Home and Remote Interface)?

Interview Question: What is the difference between ejbCreate() and ejbPostCreate?

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

Interview Question: What is the difference between sessioncontext and entitycontext?

What is the difference between jsp:include page and @ include file?

What do you understand by JSP Actions?

What is the difference between Session Bean and Entity Bean?

Latest Articles (in Interview)

Comment on this tutorial