Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Steps Required:WAR file

 
Deepak Lal
Ranch Hand
Posts: 561
Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers,

1> Can anyone give me the Manual steps for PACKAGING/CREATING and DEPLOYING and UNDEPLOYING a WAR FILE?

2> To which directory should the WAR file created be deployed in case of Application Server?

3> How to Undeploy a WAR file using a command line console?

Help provided will be Highly appreciated.

--
Deepak Lal
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64975
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1) Covered in the Servlet Specification.

2) Depends upon which app server

3) See (2)
 
Deepak Lal
Ranch Hand
Posts: 561
Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Bear and Ranchers,

Please correct me if i'm wrong Bear

1>
a> Command to be used for creating a WAR file from command prompt: jar -cvf mywarfile.war *
b> goto admin console of AS,and click on Deploy to Deploy mywarfile.war created in step1
c>goto admin console of AS and click on Undeploy to Undeploy the mywarfile.war deployed previously in step2.

2> To which directory should the WAR file created be extracted in case of Tomcat/Bea Weblogic Server? (Please help me with this)

3> How to Undeploy a WAR file from a command line console? (Please help me with this)

Help provided will be highly appreciated.

--
Deepak Lal
 
Joe Ess
Bartender
Posts: 9300
10
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Deepak Lal wrote:
b> goto admin console of AS,and click on Deploy to Deploy mywarfile.war created in step1
c>goto admin console of AS and click on Undeploy to Undeploy the mywarfile.war deployed previously in step2.

That is one way to go about it. There is also an ant task and WLST command to deploy and undeploy (which answers #3).

Deepak Lal wrote:
2> To which directory should the WAR file created be extracted in case of Tomcat/Bea Weblogic Server? (Please help me with this)


Are you deploying your WAR in Tomcat or Weblogic? They use completely different directory structures, and I'm not sure Weblogic always makes the deployed app visible (and Weblogic varies depending on the version).
 
Deepak Lal
Ranch Hand
Posts: 561
Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Joe and Bear,
Thanks for the Valuable inputs,But please clarify point#2


#1> antTask would suffice,Thanks for the answers



#2> Consider the scenario of both Tomcat and Weblogic Server.Can you tell me under which directory i need to extract/place my created WAR file in Step #1.



#3> WLST and ant Task command would suffice for undeploying a WAR file,Thanks for the answers


Help provided will be highly appreciated.

--
Deepak Lal
 
Joe Ess
Bartender
Posts: 9300
10
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Deepak Lal wrote:

#2> Consider the scenario of both Tomcat and Weblogic Server.Can you tell me under which directory i need to extract/place my created WAR file in Step #1.



I follow the suggestions in the Tomcat Developer's Guide for Source Organization. For Tomcat I deploy directly from the "dist" directory.
For Weblogic it's necessary to copy the WAR out of the distribution directory because it will keep the file open, making it impossible to overwrite it with another build. As part of the build process, I just copy the WAR to another top-level directory named "staging".
 
Shyam Sakalley
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi

(1) first of all make sure when you installed weblogic you should configured for user go through the configured wizardthen create your own domain then open bea-> userProject-> domain -> mydomain->applications and copy your WEB appcation here after that when you will start WEBLOGIC SERVER then select Deployment option then web module and then select new web module select your application remeber radio button should come ..............
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic