• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Bear Bibeault
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • salvin francis
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Frits Walraven
Bartenders:
  • Jj Roberts
  • Carey Brown
  • Scott Selikoff

Two instances of Tomcat 5.5.17

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

I have this problem:
I use a web-application running on a tomcat servlet through the 8108 port.
I have to run a second web-application, provided by the same developers team of the first one, but obviously the second web-app breaks because "8108 port is already in use".

I had never worked with a tomcat server and I don't know Java.

I have noticed that there is NO config file (as server.xml, httpd.conf, or similar stuff), the unique reference to the string "8108" I've found (after unpacking all .jar files) is stored in a .class file (PropertyReader.class).

I tried to edit the file with a java class editor (ClassEditor Version 2.23), changing the port to 8109 and the endport to 8110 (previously 8109) and then I have recompiled the directory.

Unfortunately, I get this error:



What can I do?

T.
 
Sheriff
Posts: 67502
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A single instance of Tomcat can run as many web applications as you like. Why do you need a second Tomcat instance?
 
Claudio Dawson
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, but the "second" application is provided with its own configured tomcat servlet; I've tried to copy data files of the second app in data root of "first" app, but many functions fail (searches, and some other smaller)...
 
Ranch Hand
Posts: 1051
Eclipse IDE Firefox Browser
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,,

Welcome to JavaRanch..

I think it will be useful Check this
 
Bear Bibeault
Sheriff
Posts: 67502
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Then you are not setting up the applications correctly. Running two instances of Tomcat is tricky, running two web apps in one Tomcat instance is easy.

Copy data into each others folders is likely what's causing problems. Each web app should have its own distinct folder structure and share nothing with the other.

Your time is better spent learning how to properly structure web applications than wasting it trying to run two instances of the server.
 
Claudio Dawson
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No, no folders inside each other, I've copied at same level...

Folder 1/stuff....
Folder 2/stuff.....


When I perform a search from the "Folder 2", the scope of the search is the "folder 1"....
I'm thinking to edit websearch.xml instructions, and see the way to "anchor" the request and alter the scope to the correct folder.

ps: sorry for my bad english, I'm writing "on the fly"
 
Bear Bibeault
Sheriff
Posts: 67502
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not really getting what you are saying, but if you have the web apps properly encapsulated each in their own folder hierarchies, you should be having no problems running multiple web apps in a single Tomcat instance.

If you can get each web web app properly running on their own -- and you should do nothing else until this is true -- then what issues are you having when you try to run both?
 
Ever since I found this suit I've felt strange new needs. And a tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic