Revision: 9943
Author: gaill...@google.com
Date: Tue Apr 5 06:30:56 2011
Log: Investigate test flakiness:
DevMode#doStartUpServer() fails from time to time (rarely) due
to an unknown error. Adding some logging to pinpoint the problem
Review at http://gwt-code-reviews.appspot.com/1401803
Review by: fabb...@google.com
http://code.google.com/p/google-web-toolkit/source/detail?r=9943
Modified:
/trunk/dev/core/src/com/google/gwt/dev/shell/jetty/JettyLauncher.java
=======================================
--- /trunk/dev/core/src/com/google/gwt/dev/shell/jetty/JettyLauncher.java
Wed Jan 26 10:35:35 2011
+++ /trunk/dev/core/src/com/google/gwt/dev/shell/jetty/JettyLauncher.java
Tue Apr 5 06:30:56 2011
@@ -669,9 +669,21 @@
// Now that we're started, log to the top level logger.
Log.setLog(new JettyTreeLogger(logger));
+
+ // DevMode#doStartUpServer() fails from time to time (rarely) due
+ // to an unknown error. Adding some logging to pinpoint the problem.
+ int connectorPort = connector.getLocalPort();
+ if (connector.getLocalPort() < 0) {
+ branch.log(TreeLogger.ERROR, String.format(
+ "Failed to connect to open channel with port %d (return
value %d)",
+ port, connectorPort));
+ if (connector.getConnection() == null ) {
+ branch.log(TreeLogger.TRACE, "Connection is null");
+ }
+ }
return createServletContainer(logger, appRootDir, server, wac,
- connector.getLocalPort());
+ connectorPort);
}
protected JettyServletContainer createServletContainer(TreeLogger logger,
--
http://groups.google.com/group/Google-Web-Toolkit-Contributors