V3 Build Environment

This page contains content concerning the v3 build environment.

Requirements (Draft)

  1. Must be able to build release-specific bundles. For example:
    • v3/core
    • v3/web
      • web container
      • jsf artifacts
      • jsp artifacts
    • v3/ejb
    • v3/tools
    • third party extensions
  2. Must be able to reuse build logic for creating different bundles.
  3. Must decide on an SCM. See the v3 SCM Plan for details.
  4. Must be able to modularize the glassfish workspace to better manage artifacts. These include:
    • DTDs
    • XSDs

Strategy (Draft)

This section describes the strategy used to fulfill each of the requirements.

  1. Requirement: must be able to build release-specific bundles.
    • Option 1: default method of building a bundle in maven is to use the maven-assembly-plugin. There are some drawbacks to this approach:
      • Declarative approach to specifying build logic. End up with complex descriptor files.
      • Functional gaps: maven-assembly-plugin cannot unzip of file, do token replacement and rezip the file.
    • Option 2: delegate the task of building the bundle to an Ant target.
      • Since Ant already has tasks for unzipping, token replacement, zipping and so on, there is no need to reinvent this for Maven plugin.
      • Ant targets will need to be able to resolve dependencies for those artifacts that do not exist in the workspace, but instead exist in the Maven repo.
      • The maven-antrun-plugin can be extended to expose methods for resolving repository artifacts. For example, a method could expose the org.apache.maven.artifact.resolver.ArtifactResolver class to code in an Ant task.
      • The maven-antrun-extended-plugin will be configured to run during the package phase.
      • Add Ant ArtifactResolver task to call the maven-antrun-extended-plugin to retrieve dependencies. New task will need these parameters:
        • Group id
        • Artifact id
        • Version
        • Classifier
    • Decision: option 2
  2. Requirement: must be able to reuse build logic for creating different bundles.
    • Reuse means that we have common logic and the ability to customize/extend it.
    • Option 1: use a scripting language. Upside: create classes and extend them for each build. Downside: steeper learning curve, more complexity, additional dependency.
    • Option 2: use only Ant. Have a common build.xml file with common logic and import it by build-specific build.xml files.
    • Decision: option 2
  3. Requirement: must be able to modularize the glassfish workspace to better manage artifacts.
    • Need more details on this requirement: Contact Jerome.

Task Breakdown (Draft)

This section describes the sequence of tasks needed to fulfill the requirements.


Jspwiki style: sortable

table-filter

Task Status Effort Estimate (calendar days)
Download maven-antrun-plugin code Done  
Investigate strategy and create design for maven-antrun-extended-plugin Done  
Add maven-antrun-plugin code to svn repo on java.net Done  
Develop initial version of maven-antrun-extended-plugin Done  
Add unit tests Deferred  
Add Ant ArtifactResolver task Done  
Test, adjust code, retest and commit Done  
Configure maven-antrun-extended-plugin to run during the package phase Done  
Develop error detection features in maven-antrun-extended-plugin WIP 0.5
Write Ant build.xml file to build pe-base Not started 2
Test pe-base build.xml file Not started 2
Write Ant build.xml file to build ee-base Not started 2
Factor out common tasks into common build.xml file Not started 2
Test ee-base build.xml file Not started 2
Write Ant build.xml file to build nuclear-base Not started 2
Factor out common tasks into common build.xml file Not started 2
Test nuclear-base build.xml file Not started 2
Write Ant build.xml file to build tomcat Not started 1
Factor out common tasks into common build.xml file Not started 1
Test tomcat build.xml file Not started 1

%%
%%

Feedback and Questions

This section tracks feedback and questions.

  • (Add here)