Empty HTML page in Web Mode.

77 views
Skip to first unread message

mbracken

unread,
Jul 7, 2008, 8:12:39 PM7/7/08
to Google Web Toolkit
I've run into an interesting issue, I'm not completely convinced it's
a GWT problem but wanted to post here and see if anyone has
encountered it as well.

My setup is an apache front-end to load balance with tomcat behind it
to do the work. Currently though no load balancing is taking place.
Once a user is logged they are directed to the HostPage.html which
just contains stylesheets and divs for GWT to anchor to. When
accessing the site via HTTPS everything works. Also when logging into
the site through HTTP, on the first login the user is directed to
HostPage.html everything works. However, on the second login the user
is directed to HostPage.html, but it's blank (look below). If they
try to login again or just hit refresh then everything works. The
next time they login it won't work, then it will, then it won't, then
it will..... In numerous tests it literally works or fails every
other time (again, load balancing is off). I initially thought it may
be a caching issue and added the Pragma/no-cache to the HostPage.html
and even setup a servlet filter to add Cache-Context max-age=0 to the
HTTP header. This didn't fix it, the HTTP headers were even inspected
to confirm Cache max age was coming back set to 0, and in the local
browser cach HostPage.html was getting updated each time.

So now that I'm unsure where to go next I'm wondering if it could be a
GWT issue? If you do a View-Source on the HostPage.html when it
doesn't work it literally is a blank page.

*****************
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html;
charset=windows-1252"></HEAD>
<BODY></BODY></HTML>
*****************

This page has a different DocType and charset then what I'm using.
Could there be issues with some of the GWT .cache.html files or
gwt.js? If GWT craps out on the loading could it be generating the
mystery blank HostPage.html that I'm seeing?

Any ideas, suggestions, etc would be helpful.


More info the help or confuse you...

- I'm using GWT 1.4.60

- This issue never shows up in Hosted Mode

- The javascript is currently compiled in Pretty mode (due to a GWT
issue http://code.google.com/p/google-web-toolkit/issues/detail?id=1788)

- I'm working with multiple entry points.

- This appears in both IE6 and FF 3.

- When it works, the apache access.log shows the GET of the
HostPage.html as a HTTP status code of 200 (Ok), when it doesn't work
it shows a code of 304 (Not Modified).

- Again, this only applies when accessing through HTTP. It works
under in HTTPs, I assume since the HostPage.html among other files are
always resent.






mbracken

unread,
Jul 8, 2008, 5:41:09 PM7/8/08
to Google Web Toolkit
Found a solution, hope this helps somebody. The error was not
related to GWT, but that fact that my HostPage.html was an HTML file,
not a JSP file. This was causing a weird cache issue. Once it was
changed to HostPage.jsp the problem went away.

Here are some links about the issue in Tomcat and a Forum with the
problem and solution I used.

Tomcat Issue:
https://issues.apache.org/bugzilla/show_bug.cgi?id=41849

JSP:
http://www.mail-archive.com/tomca...@jakarta.apache.org/msg50792.html
Reply all
Reply to author
Forward
0 new messages