Uploaded image for project: 'Codehaus Cargo'
  1. Codehaus Cargo
  2. CARGO-457

Add Packager API to packager a container's distribution, a Configuration and deployed Deployables


    • Type: New Feature
    • Status: Closed (View workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.8
    • Fix Version/s: 0.9
    • Component/s: Core
    • Labels:


      From a mail sent to the dev list:

      I'd like to propose introducing a new API in Cargo: the Packager API. The idea is that it would be useful for our users to ask Cargo to give them a consolidated distribution containing the container distribution files, a container configuration and deployed deployables.
      For example this would be very useful for the use case where a user wants to use Cargo to generate an application (i.e. a container, its configuration and deployed deployables).
      I'm thus proposing the introduction of the following interface:
      * Gathers an installed container distribution and a local configuration in a single location.
      * There can be several packagers like a directory packager which packeg them in a given directory
      * on the file system, a ZIP packager which does the same but packaged as a ZIP file, etc.
      * @version $Id: Container.java 886 2006-02-28 12:40:47Z vmassol $ */ public interface Packager {
      * Package an installed container distribution and its local configuration in a single location.
      * @param container the installed container to package
      void packageContainer(InstalledLocalContainer container); }
      This interface will be implemented by the different containers.
      We would also add a PackagerFactory class to return a packager for a given container.
      There could be several packager types (directory packager, zip packager, IzPack packager, etc). Thus we would also introduce a PackagerType class and use it to register packagers in the DefaultPackagerFactory class.
      Last, I'd like to introduce a new Maven2 MOJO so that users can type "mvn cargo:package". This would also mean the introduction a some new configuration elements:
      The "directory" type would be the default so no configuration element would need to be specified to use it.


          Issue links



              • Assignee:
                vincentmassol Vincent Massol
                vincentmassol Vincent Massol
              • Votes:
                0 Vote for this issue
                0 Start watching this issue


                • Created: