Re: Problem while trying to build GWT from source

2011-04-21 Thread Johannes Tuchscherer
Thomas,

Thanks for your help. I got the project set up in Eclipse and I am able to 
run the tests in there. I guess I should have checked the eclipse folder in 
my search for build instruction...
Now I am finally able to continue my work on the patch.

Thanks again,
Johannes


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Problem while trying to build GWT from source

2011-04-18 Thread Johannes Tuchscherer
I am currently trying to compile the GWT source and to run the test suite 
for the 2.3 release. 
On a clean checkout I see a lot of test failures when I just run 'ant test' 
in the user folder. Interestingly, most of the JRE test suites are passing 
(e.g. in the AutoBeanSuite the AutoBeanCodexJreTest and the AutoBeanJreTest 
are passing, but not the AutoBeanCodexTest and the AutoBeanTest), but pretty 
much all other tests have an error (no failures). At the beginning of the 
reports output files, I typically see the following message which indicates 
that something went wrong (I just don't know how to fix this):

Testsuite: com.google.gwt.autobean.AutoBeanSuite
Tests run: 58, Failures: 0, Errors: 29, Time elapsed: 16.008 sec
- Standard Output ---
[ERROR] Unable to find type 'java.lang.Object'
   [ERROR] Hint: Check that your module inherits 'com.google.gwt.core.Core' 
either directly or indirectly (most often by inheriting module 
'com.google.gwt.user.User')
-  ---

and the error recorded in the output file looks like this:

Testcase: testCycle took 13.628 sec
Caused an ERROR
(see previous log entries)
com.google.gwt.core.ext.UnableToCompleteException: (see previous log 
entries)
at com.google.gwt.dev.cfg.ModuleDef.checkForSeedTypes(ModuleDef.java:518)
at com.google.gwt.dev.cfg.ModuleDef.getCompilationState(ModuleDef.java:327)
at com.google.gwt.junit.JUnitShell.runTestImpl(JUnitShell.java:1342)
at com.google.gwt.junit.JUnitShell.runTestImpl(JUnitShell.java:1309)
at com.google.gwt.junit.JUnitShell.runTest(JUnitShell.java:650)
at com.google.gwt.junit.client.GWTTestCase.runTest(GWTTestCase.java:441)
at com.google.gwt.junit.client.GWTTestCase.run(GWTTestCase.java:296)
at java.lang.Thread.run(Thread.java:662)


I know something is wrong in my setup and I would like to know what. I am 
running ant 1.8.2 with the JDK1.6_24 on a 32bit linux machine with the 
following ANT_OPTS:
ANT_OPTS=-XX:MaxPermSize=512m -Xmx1024m -XX:+CMSClassUnloadingEnabled 
-XX:+UseConcMarkSweepGC

If you have any pointers or ideas what's wrong with the setup, please let me 
know.

Thanks in advance.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



[gwt-contrib] Fwd: Trying to address issue 6234 (Support RequestFactory service inheritance on the client) (issue1411802)

2011-04-10 Thread Johannes Tuchscherer
-- Forwarded message --
From: jtuchsche...@gmail.com
Date: Sun, Apr 10, 2011 at 00:13
Subject: Trying to address issue 6234 (Support RequestFactory service
inheritance on the client) (issue1411802)
To: jtuchsche...@gmail.com
Cc: google-web-toolkit-contributors@googlegroups.com,
re...@gwt-code-reviews.appspotmail.com


Reviewers: ,

Description:
This is a crude attempt to get methold resolving to work in cases where
the RequestContext inherits from a generic super interface and does not
contain the request method itself.

I was not able to get a local environment setup in a reasonable amount
of time or to run the tests without running out of PermGen memory space.
I hope someone else can use this patch and take this on.

With this change we will look up the RequestContext class twice from the
classloader. From my basic understanding of this code this is not going
to matter, since all these calls get cached and therefore there is a
limited number of calls. In order to make it better, though, the
SimpleRequestProcessor could first try to resolve the class (line 425)
and then call the resolveRequestContextMethod with the Class instead of
its name. For that, you would need to change the signature of
resolveRequestContextMethod to take a Class instead of a string for the
RequestContextClass. That was too much refactoring for me without being
able run tests. If I had a working local environment, that would have
been the solution I had tried.

I tried to create a test for this. I have no idea if it works or not.
:-(


Please review this at http://gwt-code-reviews.appspot.com/1411802/

Affected files:
 user/src/com/google/gwt/requestfactory/server/ResolverServiceLayer.java
 user/src/com/google/gwt/requestfactory/server/ServiceLayer.java
 user/src/com/google/gwt/requestfactory/server/ServiceLayerCache.java
 user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
 user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
 user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java


Index:
user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java
===
---
user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java
 (revision 9969)
+++
user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java
 (working copy)
@@ -65,24 +65,34 @@
RequestInteger add(int n);
RequestInteger subtract(int n);
  }
+  /**
+   * Base implementation of {@link SumServiceBase}
+   */
+  static abstract class GenericBaseImplT extends Number {
+protected T initialValue;

+public int add(int n) {
+  return initialValue.intValue() + n;
+}
+
+public int subtract(int n) {
+  return initialValue.intValue() - n;
+}
+
+public int mulitply(int n) {
+  return initialValue.intValue() * n;
+}
+  }
+
  /**
   * Base implementation of {@link SumServiceBase}
   */
-  static class BaseImpl {
+  static class BaseImpl extends GenericBaseImplInteger {
protected int initialValue;

public BaseImpl() {
  initialValue = 5;
}
-
-public Integer add(int n) {
-  return initialValue + n;
-}
-
-public Integer subtract(int n) {
-  return initialValue - n;
-}
  }

  /**
@@ -97,11 +107,6 @@
   */
  initialValue = 8;
}
-
-@Override
-public Integer subtract(int n) {
-  return 0;
-}
  }

  private static final int TEST_DELAY = 5000;
@@ -149,7 +154,7 @@
factory.subContext().subtract(3).fire(new ReceiverInteger() {
  @Override
  public void onSuccess(Integer response) {
-assertEquals((Integer) 0, response);
+assertEquals((Integer) 5, response);
finishTest();
  }
});
Index:
user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
===
--- user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
   (revision 9969)
+++ user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
   (working copy)
@@ -142,8 +142,8 @@
  }

  @Override
-  public Method resolveDomainMethod(Method requestContextMethod) {
-return getNext().resolveDomainMethod(requestContextMethod);
+  public Method resolveDomainMethod(String requestContextClass, Method
requestContextMethod) {
+return getNext().resolveDomainMethod(requestContextClass,
requestContextMethod);
  }

  @Override
Index:
user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
===
---
user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
(revision 9969)
+++
user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
(working copy)
@@ -428,7 +428,7 @@
  throw new UnexpectedException(Cannot resolve operation 
  + invocation.getOperation(), null);
}
-Method