You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Kovács István <ko...@gmail.com> on 2007/03/14 11:19:21 UTC
Catch 22 - Tapestry5 vs Maven (vs me)
Hi,
I've tried the "hilo" example given in the Tapestry5 tutorial (which
is also the first time I used Maven). The build failed:
mvn.bat archetype:create
-DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repository/
-DarchetypeGroupId=org.apache.tapestry
-DarchetypeArtifactId=quickstart -DarchetypeVersion=5.0.3-SNAPSHOT
-DgroupId=org.example -DartifactId=myapp
-DpackageName=org.example.myapp -Dversion=1.0.0-SNAPSHOT
Error message:
=====
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error creating from archetype
Embedded error: Archetype does not exist: Unable to download the
artifact from any repository
Try downloading the file manually from the project website.
Then, install it using the command:
mvn install:install-file -DgroupId=org.apache.tapestry
-DartifactId=quickstart \
-Dversion=5.0.3-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file
org.apache.tapestry:quickstart:jar:5.0.3-SNAPSHOT
from the specified remote repositories:
central (http://repo1.maven.org/maven2)
=====
I got around that by adding
-DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repository/
to the command-line. This time the build was successful.
The next step in the tutorial is: mvn jetty:run
This failed with:
=====
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error building POM (may not be this project's POM).
Project ID: org.apache.maven.plugins:maven-war-plugin
Reason: Error getting POM for
'org.apache.maven.plugins:maven-war-plugin' from the repository:
Failed to resolve artifact, possibly
due to a repository list that is not appropriately equipped for this
artifact's metadata.
org.apache.maven.plugins:maven-war-plugin:pom:2.0.3-SNAPSHOT
from the specified remote repositories:
apache.snapshots (http://people.apache.org/repo/m2-snapshot-repository/),
howardlewisship.com (http://howardlewisship.com/repository),
central (http://repo1.maven.org/maven2)
=====
Which is weird. My local repo directory has
org\apache\maven\plugins\maven-war-plugin, inside there's
maven-metadata-apache.snapshots.xml, which has:
=====
<?xml version="1.0" encoding="UTF-8"?><metadata>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.0-beta-3-SNAPSHOT</version>
<versioning>
<latest>2.0.3-SNAPSHOT</latest>
<versions>
<version>2.0-beta-3-SNAPSHOT</version>
<version>2.0-SNAPSHOT</version>
<version>2.0.1-SNAPSHOT</version>
<version>2.0.1-20060627.091727-2</version>
<version>2.0.1-20060627.092201-2</version>
<version>2.0.2-SNAPSHOT</version>
<version>2.0.3-SNAPSHOT</version>
</versions>
<lastUpdated>20070311165228</lastUpdated>
</versioning>
</metadata>
=====
I can get past this, too, by editing pom.xml, removing the repository
"apache.snapshots". The build starts after downloading a bunch more of
stuff, including some from
people.apache.org/repo2/m2-snapshot-repository. This is probably only
strange to me, who has never used maven and has not read the docs.
Unfortunately, after the promising start, if fails when building:
=====
[INFO] [compiler:compile]
[INFO] Compiling 2 source files to D:\TEMP\myapp\target\classes
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure
D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[8,42]
cannot find symbol
symbol : class Contribute
location: package org.apache.tapestry.ioc.annotations
D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[9,42]
cannot find symbol
symbol : class Id
location: package org.apache.tapestry.ioc.annotations
D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[20,1]
cannot find symbol
symbol: class Id
@Id("app")
D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[23,5]
cannot find symbol
symbol : class Contribute
location: class org.example.myapp.services.AppModule
D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[73,5]
cannot find symbol
symbol : class Contribute
location: class org.example.myapp.services.AppModule
=====
This is weird, as it did download Tapestry 5:
=====
Downloading: http://people.apache.org/repo/m2-snapshot-repository//org/apache/tapestry/tapestry-ioc/5.0.3-SNAPSHOT/tapestry-ioc-5.0.3-20070311.173413-3.jar
[...]
Downloading: http://people.apache.org/repo/m2-snapshot-repository//org/apache/tapestry/tapestry-core/5.0.3-SNAPSHOT/tapestry-core-5.0.3-20070311.173413-3.jar
=====
I'm at the end of my wit - could someone please point me in the right direction?
TIA,
Kofa
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Catch 22 - Tapestry5 vs Maven (vs me)
Posted by Davor Hrg <hr...@gmail.com>.
you should try
mvn archetype:create ↵
-DarchetypeGroupId=org.apache.tapestry ↵
-DarchetypeArtifactId=tapestry-simple ↵
-DgroupId=org.example ↵
-DartifactId=hilo ↵
-DpackageName=org.example.hilo ↵
-DarchetypeVersion=5.0.2
it works fine,
5.0.3-SNAPSHOT is curently being changed rapidly
after you have little fun with it you can try 5.0.3-SNAPSHOT
I did that by changing tapestry version in bottom of pom.xml
regarding the errors in hilo app:
@id and @Contribute are being removed from ioc so naturaly
it doesn't compile
however you can just remove those lines and the hilo app should work just
fine
Davor Hrg
On 3/14/07, Kovács István <ko...@gmail.com> wrote:
>
> Hi,
>
> I've tried the "hilo" example given in the Tapestry5 tutorial (which
> is also the first time I used Maven). The build failed:
> mvn.bat archetype:create
> -DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repository/
> -DarchetypeGroupId=org.apache.tapestry
> -DarchetypeArtifactId=quickstart -DarchetypeVersion=5.0.3-SNAPSHOT
> -DgroupId=org.example -DartifactId=myapp
> -DpackageName=org.example.myapp -Dversion=1.0.0-SNAPSHOT
>
> Error message:
> =====
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Error creating from archetype
>
> Embedded error: Archetype does not exist: Unable to download the
> artifact from any repository
>
> Try downloading the file manually from the project website.
>
> Then, install it using the command:
> mvn install:install-file -DgroupId=org.apache.tapestry
> -DartifactId=quickstart \
> -Dversion=5.0.3-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file
>
>
> org.apache.tapestry:quickstart:jar:5.0.3-SNAPSHOT
>
> from the specified remote repositories:
> central (http://repo1.maven.org/maven2)
> =====
>
> I got around that by adding
> -DremoteRepositories=http://people.apache.org/repo/m2-snapshot-repository/
> to the command-line. This time the build was successful.
>
> The next step in the tutorial is: mvn jetty:run
> This failed with:
> =====
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Error building POM (may not be this project's POM).
>
>
> Project ID: org.apache.maven.plugins:maven-war-plugin
>
> Reason: Error getting POM for
> 'org.apache.maven.plugins:maven-war-plugin' from the repository:
> Failed to resolve artifact, possibly
> due to a repository list that is not appropriately equipped for this
> artifact's metadata.
> org.apache.maven.plugins:maven-war-plugin:pom:2.0.3-SNAPSHOT
>
> from the specified remote repositories:
> apache.snapshots (http://people.apache.org/repo/m2-snapshot-repository/
> ),
> howardlewisship.com (http://howardlewisship.com/repository),
> central (http://repo1.maven.org/maven2)
> =====
>
> Which is weird. My local repo directory has
> org\apache\maven\plugins\maven-war-plugin, inside there's
> maven-metadata-apache.snapshots.xml, which has:
> =====
> <?xml version="1.0" encoding="UTF-8"?><metadata>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-war-plugin</artifactId>
> <version>2.0-beta-3-SNAPSHOT</version>
> <versioning>
> <latest>2.0.3-SNAPSHOT</latest>
> <versions>
> <version>2.0-beta-3-SNAPSHOT</version>
> <version>2.0-SNAPSHOT</version>
> <version>2.0.1-SNAPSHOT</version>
> <version>2.0.1-20060627.091727-2</version>
> <version>2.0.1-20060627.092201-2</version>
> <version>2.0.2-SNAPSHOT</version>
> <version>2.0.3-SNAPSHOT</version>
> </versions>
> <lastUpdated>20070311165228</lastUpdated>
> </versioning>
> </metadata>
> =====
>
> I can get past this, too, by editing pom.xml, removing the repository
> "apache.snapshots". The build starts after downloading a bunch more of
> stuff, including some from
> people.apache.org/repo2/m2-snapshot-repository. This is probably only
> strange to me, who has never used maven and has not read the docs.
> Unfortunately, after the promising start, if fails when building:
> =====
> [INFO] [compiler:compile]
> [INFO] Compiling 2 source files to D:\TEMP\myapp\target\classes
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD FAILURE
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Compilation failure
>
>
> D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[8,42]
> cannot find symbol
> symbol : class Contribute
> location: package org.apache.tapestry.ioc.annotations
>
>
> D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[9,42]
> cannot find symbol
> symbol : class Id
> location: package org.apache.tapestry.ioc.annotations
>
>
> D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[20,1]
> cannot find symbol
> symbol: class Id
> @Id("app")
>
>
> D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[23,5]
> cannot find symbol
> symbol : class Contribute
> location: class org.example.myapp.services.AppModule
>
>
> D:\TEMP\myapp\src\main\java\org\example\myapp\services\AppModule.java:[73,5]
> cannot find symbol
> symbol : class Contribute
> location: class org.example.myapp.services.AppModule
> =====
>
> This is weird, as it did download Tapestry 5:
> =====
> Downloading:
> http://people.apache.org/repo/m2-snapshot-repository//org/apache/tapestry/tapestry-ioc/5.0.3-SNAPSHOT/tapestry-ioc-5.0.3-20070311.173413-3.jar
> [...]
> Downloading:
> http://people.apache.org/repo/m2-snapshot-repository//org/apache/tapestry/tapestry-core/5.0.3-SNAPSHOT/tapestry-core-5.0.3-20070311.173413-3.jar
> =====
>
> I'm at the end of my wit - could someone please point me in the right
> direction?
>
> TIA,
> Kofa
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>