Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / October 2005

Tip: Looking for answers? Try searching our database.

Tomcat compiles JSP but all I get is blank

Thread view: 
jason.tomlins@gmail.com - 21 Oct 2005 16:50 GMT
Everything was fine until I restarted tomcat after just making one
change to a .java file. I recompiled, everything fine, started Tomcat
and now when I access the website the URL resolves as usual but I just
get a blank page, no errors, nothing. All my other webapps under tomcat
are still running fine. Nothing else has changed. I tried deleting the
/work directory to remove cached compiled JSP but still same. The JSPs
even get compiled when requested but are still returning an empty page.

Help. I'm lost on this one.

Thanks.
muttley - 21 Oct 2005 17:16 GMT
i get this sometimes if the tomcat thread executing the jsp / servlet
throws a low level error. look in the catalina.out and access_log files
for evidence of a 500 internal server error problem.
remove any nice error trapping as this might be hiding the default
stack trace page too.

hth

kev.
jason.tomlins@gmail.com - 21 Oct 2005 17:32 GMT
Thanks for the tip but no errors being reported in any of the logs.

Arrrggghhhh !!
Andrew Thompson - 21 Oct 2005 17:44 GMT
> Everything was fine until I restarted tomcat after just making one
> change to a .java file.

What change?

>...I recompiled, everything fine, started Tomcat
> and now when I access the website the URL

What is the URL?

>...resolves as usual but I just
> get a blank page, no errors, nothing.

Are you certain?  What is the actual *source* of the page
that arrives in the *browser*.  (And no, I'm not suggesting
you post 250 lines of HTML to the group, just a summary
will be fine)

[ Note that '<html><body><h1></h1></body></html>' will render
absolutley *nothing* in a browser. ]

Have you validated the end result of your JSP?

What browsers(s) are you using, and have they been updated
or patched recently?

Does the page use any Javascript?

Note that I might have answered all the above questions
in the time it took to type this (and perhaps solved the
problem) if you'd provided the URL...
jason.tomlins@gmail.com - 21 Oct 2005 17:56 GMT
The change I made was to a simple string in an area of the app that
would not impact JSPs. Recompilation of the file was fine)

The source returned to the browser is minimal, as in your example, just
a few lines of HTML. The JSPs are validated, no changes to jsps was
done. All was working until Tomcat restart. The jsps get compiled etc.

I am using IE6, no changes there.

Some pages us javascript some dont, the problem persists throughout.

As a test, I created a JSP called index.jsp (it contains no code, just
one line of text) and threw it in http://forums.fooforums.com , a
directory containing JSPs (prior to placing index.jsp in this directory
you could see this list of jsps but clicking on them just returned
blank pages again). This index.jsp gets compiled fine but still renders
a blank page (just minimal html), try for yourself.

Ideas ?

Thanks,
Jason.
Andrew Thompson - 21 Oct 2005 18:08 GMT
> Ideas ?

No, unfortunately.

[ The only immediate suspicion I had was that you'd
made a simple HTML error that caused every page to be
'delivered complete' but render incorrectly. Your extra
info. - ruled that out. ]
jason.tomlins@gmail.com - 21 Oct 2005 20:37 GMT
Well, I resolved the issue. There was a jsp-api.jar in the WEB-INF/lib
directory of the application in question. After removing this jar
everything was fine. Dont ask me.

Jason.
Roedy Green - 22 Oct 2005 00:50 GMT
On 21 Oct 2005 08:50:12 -0700, jason.tomlins@gmail.com wrote or quoted

>I restarted tomcat after just making one
>change to a .java file.

It looks to me like the change you made to the .java file (I presume
you meant .jsp file) is the culprit.  Back it out.

Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.