8 Replies Latest reply on Oct 17, 2007 8:35 AM by anton.otto

    2.0.0.CR2:

    tynor

      Seam 2.0.0.CR2, Windows XP, ant 1.7.0, (maven 2.0.6 is in my PATH, but I'm not conciously trying to use it with Seam)

      Something in recent mavenization has broken seamgen? I had no problems with CR1.


      [jdk1.5]:feta:/c/tools/src/jboss-seam-2.0.0.CR2> ./seam.bat setup
      Buildfile: c:\tools\src\jboss-seam-2.0.0.CR2\seam-gen\build.xml
      
      init:
      [artifact:dependencies] Downloading: org/jboss/seam/jboss-seam-gen/2.0.0.CR2/jbo
      ss-seam-gen-2.0.0.CR2.pom
      [artifact:dependencies] Downloading: org/jboss/seam/jboss-seam-gen/2.0.0.CR2/jbo
      ss-seam-gen-2.0.0.CR2.jar
      [artifact:dependencies] An error has occurred while processing the Maven artifac
      t tasks.
      [artifact:dependencies] Diagnosis:
      [artifact:dependencies]
      [artifact:dependencies] Unable to resolve artifact: Missing:
      [artifact:dependencies] ----------
      [artifact:dependencies] 1) org.jboss.seam:jboss-seam-gen:jar:2.0.0.CR2
      [artifact:dependencies]
      [artifact:dependencies] Try downloading the file manually from the project web
      site.
      [artifact:dependencies]
      [artifact:dependencies] Then, install it using the command:
      [artifact:dependencies] mvn install:install-file -DgroupId=org.jboss.seam
      -DartifactId=jboss-seam-gen \
      [artifact:dependencies] -Dversion=2.0.0.CR2 -Dpackaging=jar -Dfile=/pa
      th/to/file
      [artifact:dependencies] Alternatively, if you host your own repository you can d
      eploy the file there: mvn deploy:deploy-file -DgroupId=org.jboss.seam -Dar
      tifactId=jboss-seam-gen \
      [artifact:dependencies] -Dversion=2.0.0.CR2 -Dpackaging=jar -Dfile=/pa
      th/to/file \
      [artifact:dependencies] -Durl=[url] -DrepositoryId=[id]
      [artifact:dependencies]
      [artifact:dependencies] Path to dependency:
      [artifact:dependencies] 1) unspecified:unspecified:jar:0.0
      [artifact:dependencies] 2) org.jboss.seam:jboss-seam-gen:jar:2.0.0.CR2
      [artifact:dependencies]
      [artifact:dependencies] ----------
      [artifact:dependencies] 1 required artifact is missing.
      [artifact:dependencies]
      [artifact:dependencies] for artifact:
      [artifact:dependencies] unspecified:unspecified:jar:0.0
      [artifact:dependencies]
      [artifact:dependencies] from the specified remote repositories:
      [artifact:dependencies] central (http://repo1.maven.org/maven2)
      [artifact:dependencies]
      [artifact:dependencies]
      
      BUILD FAILED
      c:\tools\src\jboss-seam-2.0.0.CR2\seam-gen\build.xml:14: Unable to resolve artif
      act: Missing:
      ----------
      1) org.jboss.seam:jboss-seam-gen:jar:2.0.0.CR2
      
       Try downloading the file manually from the project website.
      
       Then, install it using the command:
       mvn install:install-file -DgroupId=org.jboss.seam -DartifactId=jboss-seam-
      gen \
       -Dversion=2.0.0.CR2 -Dpackaging=jar -Dfile=/path/to/file
      Alternatively, if you host your own repository you can deploy the file there:
       mvn deploy:deploy-file -DgroupId=org.jboss.seam -DartifactId=jboss-seam-gen
      \
       -Dversion=2.0.0.CR2 -Dpackaging=jar -Dfile=/path/to/file \
       -Durl=[url] -DrepositoryId=[id]
      
       Path to dependency:
       1) unspecified:unspecified:jar:0.0
       2) org.jboss.seam:jboss-seam-gen:jar:2.0.0.CR2
      
      ----------
      1 required artifact is missing.
      
      for artifact:
       unspecified:unspecified:jar:0.0
      
      from the specified remote repositories:
       central (http://repo1.maven.org/maven2)
      
      
      Total time: 1 second
      



        • 1. Re: 2.0.0.CR2:  seam-gen maven errors
          tynor

          phpbb choked on my Subject header on previous post

          • 2. Re: 2.0.0.CR2:
            pmuir

            As a workaround, run ant build in the download first.

            • 3. Re: 2.0.0.CR2:
              tynor

              Thanks Pete. That worked.

              As a workaround, run ant build in the download first.



              • 4. Re: 2.0.0.CR2:
                nickarls

                Aah, building it first did the trick.

                A small note on seam-gen:
                it suggests com.mydomain.$project_name$ as default for the session beans and $project_name$.actions as default for the entities. Previously it has been $project_name$.actions and $project_name$.model or something like that.

                • 5. Re: 2.0.0.CR2:
                  pmuir

                   

                  "nickarls" wrote:
                  Aah, building it first did the trick.


                  Apologies for this - I didn't spot this in testing :(

                  • 6. package names used by seam-gen
                    dan.j.allen

                    There was a change in seam-gen starting with Seam 2.0.0.CR2 regarding how the generated classes are organized when generate-entities is executed.

                    Old way:

                    src/model/com/domain/projectname/model/EntityName.java
                    src/action/com/domain/projectname/model/EntityNameHome.java
                    src/action/com/domain/projectname/model/EntityNameList.java

                    New way:

                    src/model/com/domain/projectname/model/EntityName.java
                    src/action/com/domain/projectname/action/EntityNameHome.java
                    src/action/com/domain/projectname/action/EntityNameList.java

                    Home and Query objects are "action" components, not "model" components and are therefore placed in the action package. This makes the result of generate-entities consistent with the result of new-entity.

                    Remember, model classes are kept separate because they cannot be hot reloaded.

                    • 7. Re: 2.0.0.CR2:
                      gersonk

                      I tried to build first (by running 'ant' in the root dir) but still these same errors occur (errors occur both during building and running 'seam setup').


                      ...
                      [artifact:dependencies] Unable to resolve artifact: Missing:
                      [artifact:dependencies] ----------
                      [artifact:dependencies] 1) javax.servlet.jsp:jsp-api:jar:2.1
                      ... a lot more errors...


                      • 8. Re: 2.0.0.CR2:

                        Remeber to build with an internet connection that does not use a proxy.