Results 1 to 3 of 3

Thread: Confusion about multiple Spring apps in the same container

Hybrid View

  1. #1
    Join Date
    Aug 2004
    Location
    Columbus, OH, USA
    Posts
    133

    Default Confusion about multiple Spring apps in the same container

    I'm confused about how to run multiple Spring applications in the same servlet container (Tomcat 5 in my case).

    For example, if I take a tested and working Spring app, copy it to a second context path in /webapps/, everything seems to load OK except the ContextLoaderListener on the second application.

    In the logs I get a message saying "2004-09-28 21:54:45,148 INFO ContextLoader.initWebApplicationContext - Published root WebApplicationContext [org.springframework.web.context.support.XmlWebAppl icationContext: displayName=[Root XmlWebApplicationContext]; startup date=[Tue Sep 28 21:54:31 GMT-05:00 2004]; root of ApplicationContext hierarchy; config locations=[/WEB-INF/classes/applicationContext.xml]; ] as ServletContext attribute with name [interface org.springframework.web.context.WebApplicationCont ext.ROOT]".

    Looks like both apps are trying to use the same root contexts - what do I need to do to keep them from colliding?

    Thanks in advance,
    Scott

  2. #2
    Join Date
    Aug 2004
    Location
    Melbourne, Australia
    Posts
    1,104

    Default

    You will at least need to change your webAppRootKey in web.xml

  3. #3
    Join Date
    Aug 2004
    Location
    Columbus, OH, USA
    Posts
    133

    Default

    You're right - thanks for the tip! For anyone else searching this thread later - I found http://www.springframework.org/docs/...tListener.html to discuss this issue exactly...
    Scott

Similar Threads

  1. Spring MVC Web Framework versus Struts
    By biguniverse in forum Web Flow
    Replies: 27
    Last Post: Aug 29th, 2012, 03:57 AM
  2. How to make runtime configurable apps with Spring?
    By wangjammer5 in forum Architecture
    Replies: 10
    Last Post: Jul 19th, 2006, 01:36 PM
  3. A Spring Class Loader?
    By azzoti in forum Architecture
    Replies: 8
    Last Post: May 7th, 2005, 04:02 AM
  4. Replies: 14
    Last Post: Feb 21st, 2005, 05:41 PM
  5. Replies: 7
    Last Post: Oct 27th, 2004, 03:40 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •