Inline.

On Sun, Feb 17, 2013 at 2:12 PM, Thomas Broyer <[email protected]> wrote:

>
> Hmm, there's
> https://github.com/tbroyer/gwt-sandbox/blob/master/user/gwt-user-core/pom.xml 
> but
> this is work in progress, and unnecessary complicated in some places. This
> is ongoing work to moving GWT itself to use Maven as the build system.
>
>
>> Many things aren't clear (to me) from the docs. Examples:
>>
>> 1). You say add a <resource> tag.
>>
>> The problem is if I add a single <resource> tag then the default
>> src/main/resources seems to be overridden, so my guess is you mean
>> something like the following added to the <build> tag:
>>
>>     <resources>
>>       <resource>
>>         <directory>src/main/resources<**/directory>
>>       </resource>
>>       <resource>
>>         <directory>src/main/super</**directory>
>>         <targetPath>com/foo/super</**targetPath>
>>       </resource>
>>     </resources>
>>
>
> Yes, that's how Maven works. src/main/resources is only the default if
> nothing's specified.
>

Understood (now). I'm just making the point that from a docs clarity POV,
it's important to tell folks to add both <resource> tags.




> And, in com.foo.Foo.gwt.xml contains
>>
>>   <super-source path="super"/>
>>
>
> Yes.
>
> Again, it's a guess since I still don't have hello-supsersource working.
>>
>> 2). The comments regarding goals are conflicting. E.g., for tests to run
>> it's suggested to add:
>>
>>           <execution>
>>             <goals>
>>               <goal>test</goal>
>>             </goals>
>>           </execution>
>>
>> But to get source-jar to run as part of install you need something like:
>>
>>           <execution>
>>             <phase>install</phase>
>>             <goals>
>>               <goal>source-jar</goal>
>>             </goals>
>>           </execution>
>>
>
> If src/main/java and src/main/super are declared as resources, then the
> sources will be added to the JAR, and you don't need a source-jar.
>

I was hoping not to put src/main/java in resources since it contains many
files that are not GWT compatible and I use JAR execution classifiers to
filter these (e.g., **/gwt/** and **/android/**, etc.) So having the
source-jar pick the appropriate files was convenient. I don't know how to
reconcile both "exections". Perhaps this is my maven ignorance.



> 3). Giving up on source-jar for the moment (i.e., just having the top
>> config), when I run tests, they just hang and timeout. In fact, if I just
>> create a blank project from the archetype, that's what happens:
>>
>> [INFO] Running junit.framework.TestSuite@**29edc073
>> Process 1361122241179 is killed.
>> [WARNING] Forked JVM has been killed on time-out after 60 seconds
>>
>
> Is this from surefire:test, failsafe:integration-test or gwt:test?
>

Out of the box, here are the errors I get (command line options given to
create archetype below my sig):

Error on "mvn test"

Tests in error:
  initializationError(com.test.client.GwtTestTest):
com/google/gwt/dev/cfg/Condition

Tests run: 1, Failures: 0, Errors: 1, Skipped: 0

Error on "gwt:test"

[INFO] Running junit.framework.TestSuite@29edc073
[INFO] [ERROR] Errors in
'file:/Users/burdon/projects/src/testing/gwt_test/src/test/java/com/example/client/GwtTestTest.java'
[INFO]    [ERROR] Line 46: No source code is available for type
com.example.client.GreetingServiceAsync; did you forget to inherit a
required module?
[INFO] [ERROR] Unable to find type 'com.example.client.GwtTestTest'
[INFO]    [ERROR] Hint: Previous compiler errors may have made this type
unavailable
[INFO]    [ERROR] Hint: Check the inheritance chain from your module; it
may not be inheriting a required module or a module may not be adding its
source path entries properly
[INFO] [ERROR] Errors in
'file:/Users/burdon/projects/src/testing/gwt_test/src/test/java/com/example/client/GwtTestTest.java'
[INFO]    [ERROR] Line 46: No source code is available for type
com.example.client.GreetingServiceAsync; did you forget to inherit a
required module?
[INFO] [ERROR] Unable to find type 'com.example.client.GwtTestTest'
[INFO]    [ERROR] Hint: Previous compiler errors may have made this type
unavailable
[INFO]    [ERROR] Hint: Check the inheritance chain from your module; it
may not be inheriting a required module or a module may not be adding its
source path entries properly


Again, this is running mvn on a freshly generated, untouched archetype.


4). Frequently, if I don't run clean first, the tests fails with
>> exceptions: e.g.,
>>
>> [INFO] Running com.foo.FooTest
>> [INFO] [ERROR] Failure in unit cache map load.
>> [INFO] java.util.concurrent.**ExecutionException:
>> java.lang.StackOverflowError
>>
>
> Hmm, this is a "pure GWT" error, unrelated to Maven (until proven
> otherwise); have you searched the GWT issue tracker? Errors in Unit cache
> loading are "expected" when upgrading GWT or changing JVM (GWT classes
> don't have a serialization ID), but obviously not in other situations.
>

Yep. It's difficult to search for this kind of thing since so far since I
haven't actually started writing any meaningful code -- just trying to
build the samples. I know this is all work in progress, but as often the
case with OS maven projects, I have no idea what is expected to be working
(e.g., many of the JS related plugins are checked in completely broken and
abandoned).

Your sandbox example is very simple -- i.e., there are no tests. Do you
know if anyone is successfully using all of the plugin's features
(supersource, test, source-jar, etc.) on a project other than GWT itself?

Thanks again,

RB


> mvn archetype:generate \
>    -DarchetypeGroupId=org.codehaus.mojo \
>    -DarchetypeArtifactId=gwt-maven-plugin \
>    -DarchetypeVersion=2.5.1-rc1
...
[INFO] Generating project in Interactive mode
[INFO] Archetype repository missing. Using the one from
[org.codehaus.mojo:gwt-maven-plugin:2.5.0] found in catalog remote
Define value for property 'groupId': : com.example
Define value for property 'artifactId': : gwt_test
Define value for property 'version':  1.0-SNAPSHOT: :
Define value for property 'package':  com.example: :
Define value for property 'module': : Test
Confirm properties configuration:
groupId: com.example
artifactId: gwt_test
version: 1.0-SNAPSHOT
package: com.example
module: Test






>  --
> You received this message because you are subscribed to the Google Groups
> "Codehaus Mojo gwt-maven-plugin Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to codehaus-mojo-gwt-maven-plugin-users+unsubscr...@googlegroups.com
> .
> To post to this group, send email to
> [email protected].
> Visit this group at
> http://groups.google.com/group/codehaus-mojo-gwt-maven-plugin-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to