Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to enforce a deployment order in tom 7 and tom6 ?

I have multiple war files to deploy, for example. coll.war, egg.war, etc., each one will specify an application module.

In our application I have some specification that coll.war should deploy first and rest has to deploy in specific sequence such like.

  1. coll.war
  2. egg.war
  3. chick.war

Can somebody help me out to do it.

like image 635
ashokramcse Avatar asked Mar 04 '14 12:03

ashokramcse


People also ask

What is deployment order?

A planning directive from the Secretary of Defense, issued by the Chairman of the Joint Chiefs of Staff, that authorizes and directs the transfer of forces between combatant commands by reassignment or attachment.

How many ways we can deploy the application into Tomcat?

As we can see, there are two ways for deploying a web application using the manager: Deploy directory or WAR file located on server. WAR file to deploy.

What is deploy path in Tomcat?

To deploy a new application, Tomcat copies its directory structure to the relevant context path in its base web apps folder, creating directories as needed. If the application provides its own Context. xml, this is copied to "$CATALINA_BASE/conf/[EngineName]/[HostName]/[ApplicationName].


1 Answers

In server.xml inside servers folders it will add a entry for every war you added.Delete those entries.

Then create the xml files which have the following content and name the xml files in order inside the conf\Catalina{server_name} folder.

Example :

coll.xml

 <?xml version='1.0' encoding='utf-8'?>
 <Context docBase="${catalina.home}/deploy/collWAR" crossContext="true">
 </Context>
like image 82
SANN3 Avatar answered Oct 20 '22 00:10

SANN3