Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7060077
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:18:33+00:00 2026-05-28T04:18:33+00:00

I know that Tomcat and the Servlet spec do not support starting webapps in

  • 0

I know that Tomcat and the Servlet spec do not support starting webapps in a particular order.

However, this seems to me like a common use case, and I’m wondering if someone has discovered a clever workaround for it.

I have webapp A which uses Spring Remoting to expose a shared service, of which webapp B is a client. Webapp B cannot initialize unless webapp A is running. However, my Tomcat is always starting the webapps linearly, starting with webapp B.

For infrastructure reasons I have to have these running on the same Tomcat server.

Any ideas?

Thanks,
Roy

UPDATE –

Turns out that in my particular case, order doesn’t matter. The reason is this: say I use one of the methods below to start app A before app B. So app A starts, but, since Spring remoting is using the HTTP Invoker, the HTTP port is not yet open (it won’t open until all apps are started). So A will start, and B will hang, because the port it’s looking for is not yet available. Doh.

End result was two separate Tomcat instances.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T04:18:34+00:00Added an answer on May 28, 2026 at 4:18 am

    We have the same problem and to solve it we’re relying on the fact (slippery, I know) that applications are started in the order they are defined in <tomcat_home>/conf/server.xml.

    This of course has a disadvantage of hardcoding apps in the server.xml but we can live with it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know that a servlet container, such as Apache Tomcat, runs in a single
I know that each servlet container (e.g. Tomcat, Glassfish, etc.) comes with an implementation
I know that I can do something like $int = (int)99; //(int) has a
I know that the MsNLB can be configured to user mulitcast with IGMP. However,
i am new to servlet programming. i want to know that... is it possible
Can the JSP servlet that filters on *.jsp (org.apache.jasper.servlet.JspServlet in Tomcat 6) be extended
I would like to get access to the Tomcat internal data from a servlet
Some frameworks (Spring, Tomcat itself) add servlet request attributes that cannot be used within
I want to know that is there any other servlet container which is better
Concerning Java EE with Tomcat we know that there is the web.xml file to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.