• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Tim Cooke
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • paul wheaton
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
  • Piet Souris
Bartenders:
  • Stephan van Hulst

we can deploy a folder instead of jar or war what is the difference

 
Ranch Hand
Posts: 167
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi all

whats the use of creating jar or war file? we can deploy domain folder directly
what's the use of deploying jar or war file instead of domain folder? what is the difference between jar (or) war

thanks in advance
 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

That is up to the container. You can deploy a folder instead of WAR file in Weblogic and Tomcat. The only thing is that the folder must follow the correct directory structure. If you want to deploy it on some other place or like that , the WAR will be easy to handle I think.

WAR means WEB ARCHIVE. JAR :- JAVA ARCHIVE.
WAR is an Web Aapplication archive and contains JSPs, "normal" static files (HTML, images, etc.), servlets, tag libraries, and such.


JAR is the "normal" Java Aapplication archive, but in this context it usually contains EJBs instead of code libraries or runnable (e.g. from outside an application container) applications
 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Albin Joseph:
Hi

That is up to the container. You can deploy a folder instead of WAR file in Weblogic and Tomcat. The only thing is that the folder must follow the correct directory structure. If you want to deploy it on some other place or like that , the WAR will be easy to handle I think.

WAR means WEB ARCHIVE. JAR :- JAVA ARCHIVE.
WAR is an Web Aapplication archive and contains JSPs, "normal" static files (HTML, images, etc.), servlets, tag libraries, and such.


JAR is the "normal" Java Aapplication archive, but in this context it usually contains EJBs instead of code libraries or runnable (e.g. from outside an application container) applications




.jar files are simple compressed files. you can put classes inside it.
While .war is also compressed file but it has to follow some directory structure as given below.

WAR file structure -
The static HTML files and JSPs are stored in the top level directory.
The Servlet and related class files must be stored in the WEB-INF/classes directory.
Any auxiliary library JAR files must be stored in the WEB-INF/lib directory.
The deployment descriptor is stored as a file named web.xml in the WEB-INF directory.
 
Get out of my mind! Look! A tiny ad!
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic