Thanks,

I found the servlet you meant: JUnitHostImpl
I see that the url that touches this servlet is correctly forwarded by
the proxy and received by this servlet when debugging in Eclipse:
The url that touches it: /
com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost (also appears
in the logging below)

However, when it's running during the nightly build and fails, I's
hard to find out what went wrong as the this servlet doesn't contain
debug/trace logging. It would be nice to see the path of execution in
the logging such that I can see why the servlet isn't touched.

Any idea's how to solve this?
Or any idea about what would be going wrong ?

Below the proxy part code that is very straightforward and some
logging that might be of interest.
In the logging I noticed that just after receiving the /junit url that
should touch the JUnitHostImpl, a retry is attempted. Does that give
you any ideas?

----
        protected void service(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException {
                final String uri = createUriRequest(request);
                LOG.debug("Receiving url request, url: {}", uri);

                if (uriContainsRequestParts(uri)) {
                        LOG.debug("Forwarding url to external system.\nUrl: 
{}\nTarget
host: {}\nTarget port: {}\nTarget protocol: {}", new Object[] { uri,
this.host,
                                        this.port, this.protocol });
                        proxy(request, response, uri);
                }
                else {
                        LOG.debug("No forward. Calling parent method. Url: {}", 
uri);
                        super.service(request, response);
                }
        }

-----
The output snippet looks like:
[INFO] 14:27:07.709 [http-0-Processor4] DEBUG
com.ited.gwt.dev.server.ProxyServlet - Receiving url request, url: /
com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost
[INFO] 14:27:07.709 [http-0-Processor4] DEBUG
com.ited.gwt.dev.server.ProxyServlet - No forward. Calling parent
method. Url: /com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost
[INFO] 14:27:10.891 [http-0-Processor4] DEBUG
com.ited.gwt.dev.server.ProxyServlet - Receiving url request, url: /bv-
web/intern/rpc-gwt/srv-general
[INFO] 14:27:10.892 [http-0-Processor4] DEBUG
com.ited.gwt.dev.server.ProxyServlet - Forwarding url to external
system.
...
...
[INFO] 14:27:12.909 [http-0-Processor4] DEBUG
com.ited.gwt.dev.server.ProxyServlet - Receiving url request, url: /
com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost
[INFO] 14:27:12.909 [http-0-Processor4] DEBUG
com.ited.gwt.dev.server.ProxyServlet - No forward. Calling parent
method. Url: /com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost
[INFO] [WARN]
com.bv.gwt.profile.intern.ProfileGwtTest.JUnit:com.bv.gwt.profile.XGwtBackendTestUpdateLoggedInMemberOk.testUpdateLoggedInTaxer
is being retried, retry attempt = 1
[INFO] [WARN]
com.bv.gwt.profile.intern.ProfileGwtTest.JUnit:com.bv.gwt.profile.XGwtBackendTestUpdateLoggedInMemberOk.testUpdateLoggedInTaxer
is being retried, retry attempt = 2
[INFO] Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed:
385.986 sec <<< FAILURE!
[INFO]
testUpdateLoggedInTaxer(com.bv.gwt.profile.XGwtBackendTestUpdateLoggedInMemberOk)
Time elapsed: 385.952 sec  <<< ERROR!
[INFO] com.google.gwt.junit.client.TimeoutException: The browser did
not contact the server within 60000ms.
[INFO]  - NO RESPONSE: 192.168.1.45 / Mozilla/5.0 (Windows; U; Windows
NT 5.1; en-US; rv:1.9.0.1) Gecko/2008070208 Firefox/3.0.1
[INFO]  - 1 client(s) haven't responded back to JUnitShell since the
start of the test.
---


On Oct 5, 2:51 pm, John Tamplin <j...@google.com> wrote:
> On Tue, Oct 5, 2010 at 8:47 AM, Ed <post2edb...@gmail.com> wrote:
> > > There are really two apps running in this case.  First, there is the one
> > > created by JUnitShell, which contacts an RPC servlet to manage running
> > the
> > > test.  The timeout you see is because that servlet didn't get contacted.
>
> > Could you please give me some more info and pointers here?
> > I find the GWT Junit code difficult to follow, especially debugging is
> > a bit hard.
> > Where and how does this required servlet get contacted to overcome the
> > timeout?
> > If I follow the service method in GWTShellServlet, I don't understand
> > where the required contact is made.
> > And I can't find the relation with the messageQueue in the method
> > JUnitShell.notdone() that must contain the required info to overcome
> > the timeout exception :(
>
> Look at the comment at the top of JUnitShell -- it explains the
> connections.
>
> > > If you need a real browser to run the test in an automated way, the
> > recommendation would be to use -runStyle Selenium:uri and run a
> > Selenium-RC
>
> > I also use Selenium, have about 2500 tests that run through Selenium,
> > that take about 50 hours to complete ;)...
> > Some background info:
> > I don't use runstyle for this. I run the tests against production
> > ready code produced during the nigtly build.
> > I run my tests through testNG with Maven surefire plugin.
>
> Right, but there your Selenium tests are exercising the running app.  I am
> suggesting it can also be used for running GWTTestCases in a real browser
> automatically.
>
> --
> John A. Tamplin
> Software Engineer (GWT), Google

-- 
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to