Meaningless Drivel is fun!*
The moose likes Tomcat and the fly likes TomCat refuse to execute init(), but WebLogic could! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "TomCat refuse to execute init(), but WebLogic could!" Watch "TomCat refuse to execute init(), but WebLogic could!" New topic
Author

TomCat refuse to execute init(), but WebLogic could!

Jes Sie
Ranch Hand

Joined: Jul 24, 2001
Posts: 188
Dear TomCat people,
I'm currently having a hard time to get TomCat 4.1.12 to execute my Servlet's public void init() or init(ServletConfig servletconfig) methods.
If the same war file is dumped to WebLogic 6.1, it works fine!
I'm merely trying to start a generic framework servlet which 'prepares' for the main application (running in Struts 1.1 beta2).
Here's the snippet of my web.xml for those who could help, thanks: -

Please help.


Thank you.<br /> <br />- Jess Sie<br /> <a href="mailto:jess@see-consulting.com" rel="nofollow">jess@see-consulting.com</a>
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16019
    
  20

I'm sitting in front of a Tomcat application that has a load-on-startup servlet with an init() in it. I've never had a problem, and this isn't the first or only such application I've done that way.
You might check your logs carefully to see if you have some WebLogic-specific code that's causing an exception to be thrown in the init() method.


Customer surveys are for companies who didn't pay proper attention to begin with.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16019
    
  20

Oh yeah - the application I mentioned is running Struts, too!
Jes Sie
Ranch Hand

Joined: Jul 24, 2001
Posts: 188
THANKS. My fault. I'm quite a newbie on TomCat. Yes, yes, everything is shown on the file log and not on the console log like WebLogic.
Any idea how to re-direct log into the console?
One other question, can anyone tell me how to deploy a war file into TomCat without having TomCat to auto explode it. The auto exploding is causing me to remove the directory every time I require I deploy an updated war file.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: TomCat refuse to execute init(), but WebLogic could!