Uploaded image for project: 'Forge'
  1. Forge
  2. FORGE-1030

Support multi-module Forge plugins

XMLWordPrintable

      1. Install Forge 1.3.3.Final.
      2. forge install-plugin nazgul
      3. Accept to install the plugin despite Forge's warnings
      4. sigh

      It seems that Forge really needs better support for the default Maven
      development process. In repository.yaml, Forge plugins are defined by giving
      a Maven project GAV for the project holding the forge plugin definitions, as well as the GitHub repository holding the plugin source.

      Yet, Forge seems to ignore the Maven GAV information given in repository.yaml when checking out and building the plugin locally.
      This is a rather nasty bug, which in its current state effectively prevents anyone from using a multi-module build for their plugins (and it is also undocumented).

      An example is shown below:

      [no project] Nazgul $ forge install-plugin nazgul
      ***INFO*** Preparing to install plugin: nazgul
      ***INFO*** Checking out plugin source files to [/var/folders/6g/9n7r543d2bv9n2qjvnvf_hsh0000gn/T/forgetemp6186363544408555570] via 'git'
      ***INFO*** Switching to branch/tag [refs/heads/1.3.3.Final]
       ? The project does not appear to be a Forge Plugin Project, install anyway? [y/N]
      

      While this analysis by Forge is incorrect (the Maven GAV given in the repository.yaml is indeed a project which holds plugins), it gets worse after installation:

      [INFO] ------------------------------------------------------------------------
      [INFO] Reactor Summary:
      [INFO]
      [INFO] nazgul-forge-parent ............................... SUCCESS [7.921s]
      [INFO] nazgul-forge-api-parent ........................... SUCCESS [4.345s]
      [INFO] nazgul-forge-model-parent ......................... SUCCESS [1.274s]
      [INFO] nazgul-forge-reactor .............................. SUCCESS [0.847s]
      [INFO] nazgul-forge-poms-reactor ......................... SUCCESS [0.058s]
      [INFO] nazgul-forge-analyzer-api ......................... SUCCESS [5.562s]
      [INFO] nazgul-forge-analyzer-impl-nazgul ................. SUCCESS [1.666s]
      [INFO] nazgul-forge-analyzer-reactor ..................... SUCCESS [0.020s]
      [INFO] nazgul-forge-factory-model ........................ SUCCESS [2.434s]
      [INFO] nazgul-forge-factory-api .......................... SUCCESS [7.634s]
      [INFO] nazgul-forge-factory-impl-nazgul .................. SUCCESS [2.724s]
      [INFO] nazgul-forge-factory-reactor ...................... SUCCESS [0.032s]
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD SUCCESS
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 36.580s
      [INFO] Finished at: Mon Jul 22 07:46:48 CEST 2013
      [INFO] Final Memory: 49M/247M
      [INFO] ------------------------------------------------------------------------
      ***INFO*** Cleaning up temp workspace [/var/folders/6g/9n7r543d2bv9n2qjvnvf_hsh0000gn/T/forgetemp6186363544408555570]
      Deleted /var/folders/6g/9n7r543d2bv9n2qjvnvf_hsh0000gn/T/forgetemp6186363544408555570
      ***ERROR*** Exception encountered: Build artifact [nazgul-forge-reactor-1.0.1-SNAPSHOT.pom] is missing and cannot be installed. Please resolve build errors and try again. (type "set VERBOSE true" to enable stack traces)
      

      So ...

      1. The repository.yaml includes a full Maven GAV to the project which holds Forge plugins.
      2. Forge uses repository.yaml to download the source from GitHub and build it
      3. Forge ignores the Maven GAV given in repository.yaml, and simply uses the root reactor project to inspect and attempt to install the plugins.

      To fix this bug, Forge needs to find the project given within the repository.yaml within the downloaded reactor and install the plugins from that project.

              rhn-support-ggastald George Gastaldi
              jgurureurope Lennart Jörelid (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: