Uploaded image for project: 'Jetspeed 2 (Retired)'
  1. Jetspeed 2 (Retired)
  2. JS2-304

Build Process Clean Up

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0-M4
    • 2.0-M4
    • Project Build
    • None

    Description

      Jetspeed2 current build process is a bit confusing. Through the various evolutions of J2 build process, many targets have been accumulated that make it difficult to easily understand the build process flow.

      Cleaning up the build process

      Using J2 in its current form requires an in-depth understanding of how J2 build internals operate.

      As an example, an integrator wanting to get starting with J2 will want to start with the portal web application and customize it from there. It should be made easy for integrators to get started with the web application without requiring an in-depth understanding of the various sequences in the build process.

      A typical implementation will want to create a project as described below:

      \sample-portal
      +---\etc Contains the build dependencies definition.
      +---\portal-webapp Contains the portal web application being built.
      +---\src Contains the portal initialization source (db scripts, etc).

      Building the portal in this structure should be possible by leveraging the deployed Jetspeed dependencies:

      • Components: All libraries (jars) required for the runtime operation of the portal engine.
      • Portlets: All web libraries (wars) required for the runtime operation of the portal engine.

      Integrator using Jetspeed2 should be able to do so easily and to easily get (through dependencies) the
      latest versions of the release Jetspeed components (libraries as well as portlets).

      The current maven-plugin and portal build implementation rely on the source build (target directories) rather than the dependencies for the assembly of the portal engine, making it more difficult to get quickly started and to keep up with enhanced components.

      Proposed changes

      The proposed changes below clean up the build process and slightly reorganize some elements to more easily achieve the goals outlined above.

      The first changes restructure the portal directory as follow.

      1. Remove all non web related dependencies from portal:
        1. Move the portal java source and java tests to components/portal. This becomes a component that will
          be released as jetspeed-(version).jar
        2. Rename the web application to portal-webapp and the artifact id to jetspeed-portal (to remove conflict
          with the jetspeed component artifact).
        3. Move the test directory under portal-webapp to components/portal/test as it support the portal
          components tests.
        4. Add org.apache.jetspeed.PortalTestConstants to centralize initialization of JETSPEED_PROPERTIES_PATH
          and PORTAL_WEBAPP_PATH.

      Clean up the portal-webapp (previously portal) build and maven-plugin.

      1. Clean portal/maven.xml:
        1. Remove commented calls to targets.
      2. The deploy and undeploy calls in the portal-webapp (previously portal) build process should be using the
        maven-plugin to do so. Multiple deploy, undeploy, register, unregister behaviors create confusion.
        Therefore, I propose to perform the following cleanup in the portal-webapp (previously portal):
        1. Remove pam.template.deploy. This is not used.
        2. Remove pam.unregister. Depends on
          pam.template.register which is not being used.
        3. Remove pam.template.register. This is not used.
        4. Remove pam.template.undeploy. There is a
          jetspeed2:undeploy target in the jetspeed plugin.
        5. Rename pam.register to pam.layoutdeploy. This really deploys the layout portlet and should be consistent with the other deploy targets.
        6. Rename pam.deploy to pam.demodeploy. This deploys the demo application.
        7. Rename pam.undeploy to pam.demoundeploy. This undeploys the demo applications.
        8. Rename pam.rss to pam.rssdeploy for consistency purpose.
        9. Modify the pam.(portlet)undeploy targets to use the jetspeed maven plugin jetspeed2:undeploy target.
        10. Remove deployJar and deployClasses. portal-webapp now uses dependencies for the portal component
          library.
        11. Remove jar:jar target.
        12. Clean plugin.jelly: jetspeed2:register and jetspeed2:unregister. Not used.

      Have portal-webapp depend on the built Portlet dependencies rather that the build target directories.

      1. Modify the maven.xml pam.(portlet)deploy target and the maven-plugin to use the archived portlet war
        deployed to the repository (maven install).

      Attachments

        Activity

          People

            dlestrat David LeStrat
            dlestrat David LeStrat
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: