• Post Reply Bookmark Topic Watch Topic
  • New Topic

503 JSP has been marked unavailable

 
Richard Hands
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
We've been developing a XML/XSL/JSP/Servet based web application, running development on Tomcat 4.1.29, and connecting to an oracle 8i database using the oracle classes12.jar jdbc stuff.
The problem we are seeming to get, with alarming inconsistency, is that once a page errors (e.g. maybe a piece of sql failed in a jsp), tomcat returns a 503 error for the page. After this point, all subsequent attempts to access that page, result in
503 - This JSP has been marked unavailable.
the only way to get round this is to stop and restart tomcat.
All the code is in try/catch blocks, catching Exception, and not throwing them back any further up the chain, and at the end of all jsp's, database connections are terminated (again, in try catch blocks).
This is a major stability issue for us, as we cannot afford to deploy an application to the market that requires the entire webserver program to be stopped and restarted every time there's a minor problem.
I have searched everywhere i can think, and can't find anything to indicate if it's A) some web container configuration issue. B) some piece of programming the JSP's/Servlets that we are doing wrong.
(Also, even though the session timeout is disabled, variables in the session object seem to be vanishing after 10 minutes or so of user inactivity. does this one sound familiar to anyone?)
cheers
Richard Hands
Senior Analyst Programmer.
 
Prakash Dwivedi
Ranch Hand
Posts: 452
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Richards,
May be you should try tools like JMeter, to pin point the exact error. Normally 503 occurs due to overloading of Web-Server.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65519
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You mentioned that you catch and handle all the errors yourelf (I'd be interested to know why, rather than using the built-in error mechanisms -- what do you eventually show the end user?). Is it possible that anywhere in your error handling scheme that you are throwing an UnavailableException? The container, if it receives this exeception, will take the servlet (or JSP-generated servlet) out of service.
 
Richard Hands
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thats an interesting question Bear.
Thinking on it, i seem to recall seeing at least one of those somewhere in someone's code. I'll go and see if i can track those down and get rid.
Thanks
 
Richard Hands
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Bear.
There were over 100 instances of throwing an unavailableexception.
Guess thats what you get for starting to write a system whilst you're still in the throes of learning java, and then copying and pasting error handling with a fundamental flaw throughout the whole system
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65519
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The best lessons are those that make you bleed.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!