1 2 Previous Next 22 Replies Latest reply: Dec 1, 2009 5:15 PM by Andrew Rubinger RSS

Maven JBoss AS Embedded Build "Profile with id: 'dist-zip' h

Lewis Gass Newbie

The build will actually make the final zip distro in the maven 2 repository.

  • 1. Re: Maven JBoss AS Embedded Build
    Lewis Gass Newbie

    Rather I meant, it does NOT make the final distro-zip in the repository, thus causing the embedded build to fail.

  • 2. Re: Maven JBoss AS Embedded Build
    Andrew Rubinger Master

    The "dist-zip" profile is applied to the JBossAS build of repos/jbossas/tags/ JBoss_6_0_0_M1. Works here:

    [INFO] Reading assembly descriptor: src/assembly/jboss-dist.xml
    [INFO] Building zip: /home/alr/business/jboss/wc/jbossas/tags/JBoss_6_0_0_M1/build/target/jboss-as-distribution-6.0.0.M1.zip
    [INFO] [install:install]
    [INFO] Installing /home/alr/business/jboss/wc/jbossas/tags/JBoss_6_0_0_M1/build/pom.xml to /home/alr/.m2/repository/org/jboss/jbossas/jboss-as-distribution/6.0.0.M1/jboss-as-distribution-6.0.0.M1.pom
    [INFO] Installing /home/alr/business/jboss/wc/jbossas/tags/JBoss_6_0_0_M1/build/target/jboss-as-distribution-6.0.0.M1.zip to /home/alr/.m2/repository/org/jboss/jbossas/jboss-as-distribution/6.0.0.M1/jboss-as-distribution-6.0.0.M1.zip


    ...as per the instructions detailed here:

    http://www.jboss.org/community/docs/DOC-14137

    S,
    ALR

  • 3. Re: Maven JBoss AS Embedded Build
    Joshua Davis Expert

    Having the same issue today. I re-build JBoss AS with

    mvn -Pdist-zip clean install


    Then I get the following when building embedded-trunk:
     $ mvn clean install
    ... blah blah blah ...
    [INFO] [dependency:unpack {execution: unpack}]
    [INFO] Configured Artifact: org.jboss.jbossas:jboss-as-distribution:6.0.0.M1:zip
    Downloading: http://repository.jboss.org/maven2/org/jboss/jbossas/jboss-as-distribution/6.0.0.M1/jboss-as-distribution-6.0.0.M1.zip
    Downloading: http://repo1.maven.org/maven2/org/jboss/jbossas/jboss-as-distribution/6.0.0.M1/jboss-as-distribution-6.0.0.M1.zip
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Unable to find artifact.
    
    Embedded error: 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.jboss.jbossas -DartifactId=jboss-as-distribution -Dversion=6.0.0.M1 -Dpackaging=zip -Dfile=/path/to/file
    
    Alternatively, if you host your own repository you can deploy the file there:
     mvn deploy:deploy-file -DgroupId=org.jboss.jbossas -DartifactId=jboss-as-distribution -Dversion=6.0.0.M1 -Dpackaging=zip -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
    
    
     org.jboss.jbossas:jboss-as-distribution:zip:6.0.0.M1
    
    from the specified remote repositories:
     snapshots.jboss.org (http://snapshots.jboss.org/maven2),
     central (http://repo1.maven.org/maven2),
     repository.jboss.org (http://repository.jboss.org/maven2)
    


    I looked in ~/.m2/repository and there was no zip file. Maybe that profile is something in settings.xml that I'm missing?

    Environment:
    * http://anonsvn.jboss.org/repos/jbossas/tags/JBoss_6_0_0_M1
    * http://anonsvn.jboss.org/repos/jbossas/projects/embedded/trunk
    * Java 1.6.0_07 64 bit server version
    * Maven 2.0.9
    * Darwin (Mac OSX)



  • 4. Re: Maven JBoss AS Embedded Build
    jaikiran pai Master

    The "dist-zip" profile is configured in the "build" module of the AS. And looks like there has been a change in the pom.xml of the AS aggregator module: http://viewvc.jboss.org/cgi-bin/viewvc.cgi/jbossas/tags/JBoss_6_0_0_M1/pom.xml?r1=94042&r2=95686. It no longer includes the "build" module. So effectively, the dist-zip profile is never invoked.

    So, "cd" to the "build" folder in the checked out location of AS and run the following command:

    mvn clean install -P dist-zip


  • 5. Re: Maven JBoss AS Embedded Build
    jaikiran pai Master

    The wiki has been updated accordingly.

  • 6. Re: Maven JBoss AS Embedded Build
    Lewis Gass Newbie

    When I follow those instructions I get the following output:

    [INFO] Scanning for projects...
    [INFO] ------------------------------------------------------------------------
    [INFO] Building JBoss Application Server Distribution
    [INFO] task-segment: [clean, install]
    [INFO] ------------------------------------------------------------------------
    [INFO] [clean:clean]
    [INFO] [enforcer:enforce {execution: enforce-plugin-versions}]
    [INFO] [enforcer:enforce {execution: enforce-java-version}]
    [INFO] [enforcer:enforce {execution: enforce-maven-version}]
    [INFO] [enforcer:enforce {execution: ban-bad-dependencies}]
    [INFO] [enforcer:enforce {execution: enforce-java-maven-versions}]
    [INFO] [site:attach-descriptor]
    [INFO] [source:jar-no-fork {execution: attach-sources}]
    [INFO] [assembly:single {execution: default}]
    [INFO] Reading assembly descriptor: src/assembly/jboss-dist.xml
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to create assembly: Error creating assembly archive : You must set at least one file.
    
    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 6 seconds
    [INFO] Finished at: Mon Nov 30 09:50:34 MST 2009
    [INFO] Final Memory: 26M/48M
    [INFO] ------------------------------------------------------------------------
    


  • 7. Re: Maven JBoss AS Embedded Build
    Lewis Gass Newbie

    I also tried copying the dist-zip maven profile to the main pom.xml and I get the following:

    [Mon Nov 30 09:58:16 MST 2009] Running in: J:/Development/Java/workspace/developer_ui/target/jboss
    [INFO] Scanning for projects...
    [INFO] Reactor build order:
    [INFO] JBossAS Component Matrix
    [INFO] JBoss Application Server Parent POM
    [INFO] JBoss Application Server Main
    [INFO] JBoss Application Server J2SE
    [INFO] JBoss Application Server MBeans
    [INFO] JBoss Application Server JMX
    [INFO] JBoss Application Server System
    [INFO] JBoss Application Server System JMX
    [INFO] JBoss Application Server Security
    [INFO] JBoss Application Server Deployment
    [INFO] JBoss Application Server Server
    [INFO] JBoss Application Server JBossAS
    [INFO] JBoss Application Server JBossAS Remoting
    [INFO] JBoss Application Server JBossAS JMX Remoting
    [INFO] JBoss Application Server JMX Remoting
    [INFO] JBoss Application Server Aspects
    [INFO] JBoss Application Server Profile Service
    [INFO] JBoss Application Server Connector
    [INFO] JBoss Application Server IIOP
    [INFO] JBoss Application Server EJB3
    [INFO] JBoss Application Server Messaging
    [INFO] JBoss Application Server Cluster
    [INFO] JBoss Application Server Varia
    [INFO] JBoss Application Server Management
    [INFO] JBoss Application Server Tomcat
    [INFO] JBoss Application Server Webservices
    [INFO] JBoss Application Server Hibernate Integration
    [INFO] JBoss Application Server Console
    [INFO] JBoss Application Server Spring Integration
    [INFO] JBoss Application Server Client POM
    [INFO] JBoss Application Server Admin Client
    [INFO] ------------------------------------------------------------------------
    [INFO] Building JBossAS Component Matrix
    [INFO] task-segment: [clean, install]
    [INFO] ------------------------------------------------------------------------
    [INFO] [clean:clean]
    [INFO] Deleting file set: J:\Development\Java\workspace\developer_ui\target\jboss\component-matrix\target (included: [**], excluded: [])
    [INFO] [enforcer:enforce {execution: enforce-plugin-versions}]
    [INFO] [enforcer:enforce {execution: enforce-java-version}]
    [INFO] [enforcer:enforce {execution: enforce-maven-version}]
    [INFO] [enforcer:enforce {execution: ban-bad-dependencies}]
    [INFO] [site:attach-descriptor]
    [INFO] [source:jar-no-fork {execution: attach-sources}]
    [INFO] [install:install]
    [INFO] Installing J:\Development\Java\workspace\developer_ui\target\jboss\component-matrix\target\pom-transformed.xml to C:\Users\elponderador\.m2\repository\org\jboss\jbossas\jboss-as-component-matrix\6.0.0.M1\jboss-as-component-matrix-6.0.0.M1.pom
    [INFO] ------------------------------------------------------------------------
    [INFO] Building JBoss Application Server Parent POM
    [INFO] task-segment: [clean, install]
    [INFO] ------------------------------------------------------------------------
    [INFO] [clean:clean]
    [INFO] [enforcer:enforce {execution: enforce-plugin-versions}]
    [INFO] [enforcer:enforce {execution: enforce-java-version}]
    [INFO] [enforcer:enforce {execution: enforce-maven-version}]
    [INFO] [enforcer:enforce {execution: ban-bad-dependencies}]
    [INFO] [enforcer:enforce {execution: enforce-java-maven-versions}]
    [INFO] [site:attach-descriptor]
    [INFO] [assembly:single {execution: default}]
    [INFO] Reading assembly descriptor: assembly/jboss-dist.xml
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to create assembly: Error creating assembly archive : You must set at least one file.
    
    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 14 seconds
    [INFO] Finished at: Mon Nov 30 09:58:31 MST 2009
    [INFO] Final Memory: 35M/63M
    [INFO] ------------------------------------------------------------------------
    


  • 8. Re: Maven JBoss AS Embedded Build
    Paul Gier Master

    Here are the correct steps for building 6.0.0.M1:
    cd build
    ./build.sh (this runs the ant build)
    mvn install (if you want the zip)

  • 9. Re: Maven JBoss AS Embedded Build
    Andrew Rubinger Master

    I've updated the Wiki instructions. Apologies; all had worked for me as I'd long ago used the Ant build first.

  • 10. Re: Maven JBoss AS Embedded Build
    Lewis Gass Newbie

    That work just fine, thanks!

  • 11. Re: Maven JBoss AS Embedded Build
    Lewis Gass Newbie

    I am hitting a problem with the embedded maven target. During the test-suite run it fails. It is related to insufficient heap space. I have upped the heap space to 1.5G and it is still failing. Any ideas?

  • 12. Re: Maven JBoss AS Embedded Build
    Andrew Rubinger Master

    Please post your configuration. Which target, and what's running out of space?

    S,
    ALR

  • 13. Re: Maven JBoss AS Embedded Build
    Lewis Gass Newbie

    When I run the "mvn clean install" on the jboss embedded as is specified http://www.jboss.org/community/docs/DOC-14137 once it gets to the test suite it spits out this after running for some time:

    [INFO] [surefire:test {execution: integration-test}]
    [INFO] Surefire report directory: J:\Development\Java\workspace\developer_ui\jboss-embedded\testsuite\target\surefire-reports
    
    -------------------------------------------------------
     T E S T S
    -------------------------------------------------------
    Running org.jboss.embedded.testsuite.ServerIntegrationTest
    Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 51.842 sec <<< FAILURE!
    
    Results :
    
    Tests in error:
     org.jboss.embedded.testsuite.ServerIntegrationTest
    
    Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
    
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] There are test failures.
    
    Please refer to J:\Development\Java\workspace\developer_ui\jboss-embedded\testsuite\target\surefire-reports for the individual test results.
    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 2 minutes 16 seconds
    [INFO] Finished at: Mon Nov 30 14:05:08 MST 2009
    [INFO] Final Memory: 58M/103M
    [INFO] ------------------------------------------------------------------------
    


    If I look at the surefire reports it has this:

    14:05:04,233 ERROR [ScopedProfileServiceController] Error installing to Deploy: name=ProfileKey@112bd54[domain=default, server=default, name=applications] state=Start mode=On Demand requiredState=Installed
    java.lang.OutOfMemoryError: Java heap space
     at java.util.Arrays.copyOf(Arrays.java:2882)
     at java.lang.AbstractStringBuilder.expandCapacity(AbstractStringBuilder.java:100)
     at java.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:597)
     at java.lang.StringBuilder.append(StringBuilder.java:212)
     at java.lang.StackTraceElement.toString(StackTraceElement.java:157)
     at java.lang.String.valueOf(String.java:2827)
     at java.lang.StringBuilder.append(StringBuilder.java:115)
     at java.lang.Throwable.printStackTraceAsCause(Throwable.java:538)
     at java.lang.Throwable.printStackTrace(Throwable.java:516)
     at org.apache.log4j.spi.ThrowableInformation.getThrowableStrRep(ThrowableInformation.java:59)
     at org.apache.log4j.spi.LoggingEvent.getThrowableStrRep(LoggingEvent.java:342)
     at org.apache.log4j.WriterAppender.subAppend(WriterAppender.java:304)
     at org.apache.log4j.WriterAppender.append(WriterAppender.java:159)
     at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:230)
     at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:65)
     at org.apache.log4j.Category.callAppenders(Category.java:203)
     at org.apache.log4j.Category.forcedLog(Category.java:388)
     at org.apache.log4j.Category.log(Category.java:853)
     at org.jboss.logging.log4j.Log4jLoggerPlugin.error(Log4jLoggerPlugin.java:241)
     at org.jboss.logging.Logger.error(Logger.java:419)
     at org.jboss.system.server.profileservice.repository.ProfileDeployAction.install(ProfileDeployAction.java:65)
     at org.jboss.system.server.profileservice.repository.AbstractProfileAction.install(AbstractProfileAction.java:53)
     at org.jboss.system.server.profileservice.repository.AbstractProfileService.install(AbstractProfileService.java:403)
     at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
     at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1633)
     at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:935)
     at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1083)
     at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:985)
     at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:775)
     at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:540)
     at org.jboss.system.server.profileservice.repository.AbstractProfileService.registerProfile(AbstractProfileService.java:308)
     at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:258)
    14:05:07,566 INFO [ProfileServiceBootstrap] Loading profile: ProfileKey@1d9a2ab[domain=default, server=default, name=all]
    


    I have upped the heap space using MAVEN_OPTS environment setting to:

    -Xmx1536m -XX:MaxPermSize=128m

    And it still runs out of memory.

  • 14. Re: Maven JBoss AS Embedded Build
    Andrew Rubinger Master

    Instead of MAVEN_OPTS, bump the values in the build/pom.xml Surefire configuration, which controls what's passed into to the test processes. Out of curiosity, what's your environment? The values there now suffice for me on both Fedora and RHEL under Sun JDK6 x86_64.

    S,
    ALR

1 2 Previous Next