Multi-module Maven project is not being updated

Issue #203 closed
Simon Narkprasert created an issue

I am evaluating versioneye and setup versioneye for a multi-module Maven project. The configuration in the Maven parent pom looks like this:

<plugin>
    <groupId>com.versioneye</groupId>
    <artifactId>versioneye-maven-plugin</artifactId>
    <version>3.9.1</version>
    <configuration>
        <apiKey>REMOVED_HERE</apiKey>
        <projectId>56ec087638ecc1000a549f80</projectId>
        <updatePropertiesAfterCreate>false</updatePropertiesAfterCreate>
    </configuration>
</plugin>

I setup a job in Jenkins, which runs once a day and executes mvn versioneye:update. In the log I see that each module is executed successfully. However when I visit the project on the webpage, I see that there is no change and still the old version is displayed (only the timestamp is updated). I thought maybe this is because I am currently using the free plan, but there should be an error message at least.

Also if I try to include some npm web assets it says Successfully updated your project file from .../package.json But I cannot see any change on the versioneye project page.

[nmc-master] $ /opt/apache-maven/bin/mvn versioneye:update
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO] 
[INFO] NMC-pom
[INFO] NMC-COMMON
[INFO] NMC
[INFO] NMC-st
[INFO] NMC-DATABASE
[INFO] NMC-RAD
[INFO] NMC-ASSEMBLY
[INFO] NMC-WEB
[INFO] MONA-SIMULATOR
[INFO] NMC-TOOLS
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-pom 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-pom ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 0
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-COMMON 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-COMMON ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 10
[INFO] Outdated: 1
[INFO]  - pl.project13.maven/git-commit-id-plugin:2.2.0 -> 2.2.1
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 16
[INFO] Outdated: 2
[INFO]  - org.xmlunit/xmlunit-core:2.0.0 -> 2.1.0
[INFO]  - org.xmlunit/xmlunit-matchers:2.0.0 -> 2.1.0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-st 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-st ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 4
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-DATABASE 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-DATABASE ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 6
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-RAD 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-RAD ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 143
[INFO] Outdated: 2
[INFO]  - javax.xml/jaxrpc-api:1.1 -> 1.1.3
[INFO]  - javax.servlet/javax.servlet-api:3.0.1 -> 3.1.0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-ASSEMBLY 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-ASSEMBLY ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 4
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-WEB 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-WEB ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 18
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building MONA-SIMULATOR 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ MONA-SIMULATOR ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 9
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building NMC-TOOLS 2.7.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- versioneye-maven-plugin:3.9.1:update (default-cli) @ NMC-TOOLS ---
[INFO] .
[INFO] Starting to update dependencies to server. This can take a couple seconds ... 
[INFO] .
[INFO] .
[INFO] Project name: NMC-pom
[INFO] Project id: 56ec087638ecc1000a549f80
[INFO] Dependencies: 4
[INFO] Outdated: 0
[INFO] 
[INFO] You can find your updated project here: https://www.versioneye.com/user/projects/56ec087638ecc1000a549f80
[INFO] 
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] NMC-pom ............................................ SUCCESS [  2.998 s]
[INFO] NMC-COMMON ......................................... SUCCESS [  2.232 s]
[INFO] NMC ................................................ SUCCESS [  2.398 s]
[INFO] NMC-st ............................................. SUCCESS [  2.150 s]
[INFO] NMC-DATABASE ....................................... SUCCESS [  2.077 s]
[INFO] NMC-RAD ............................................ SUCCESS [  6.201 s]
[INFO] NMC-ASSEMBLY ....................................... SUCCESS [  2.013 s]
[INFO] NMC-WEB ............................................ SUCCESS [  2.403 s]
[INFO] MONA-SIMULATOR ..................................... SUCCESS [  2.359 s]
[INFO] NMC-TOOLS .......................................... SUCCESS [  2.245 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 27.267 s
[INFO] Finished at: 2016-03-28T22:08:43+00:00
[INFO] Final Memory: 15M/170M
[INFO] ------------------------------------------------------------------------

Comments (8)

  1. Robert Reiz

    Hi @simdevmon. If you are using the VersionEye Maven Plugin on a multi module project in the parent pom, you should remove this 2 lines from the configuration:

    <projectId>56ec087638ecc1000a549f80</projectId>
    <updatePropertiesAfterCreate>false</updatePropertiesAfterCreate>
    

    The Plugin will walk through all of your modules and create for each module a versioneye.properties file which contains the project ID for the module. Each module is a separate project on the VersionEye server. But the Plugin will attach all modules/projects to the parent project, so that you get a unified view on the server over all your modules.

    I would recommend that you remove the current project from the server and remove the 2 configuration lines. Then run

    mvn versioneye:create
    

    on your localhost. After that you should see the versioneye.properties files in each module. Commit and push them to your SCM and then run on each build on your CI system:

    mvn versioneye:update
    

    The Project ID in the versioneye.properties files are the connections between your modules and the projects on the server.

    Let me know if that works for you. If you need more help we can setup a screen sharing session. Shouldn't take longer than 5 minutes to setup the project.

  2. Simon Narkprasert reporter

    Hi @reiz . Thank you for the quick response.

    My goal was to avoid having a separate versioneye.properties file for each module, but to only have VersionEye related configuration in the parent pom. That is why I used the information from here: https://github.com/versioneye/versioneye_maven_plugin#mvn-versioneyeupdate, but was not clear to me that each module is a separate project on the VersionEye server. So I guess it is not possible to keep VersionEye related config out of the modules.

    I did it now as suggested and it works fine now (I had to delete the old project before).

    Personally I would prefer to have only one parent project on VersionEye server with sub modules as well and the possibility to integrate other assets like web modules there as well.

  3. Robert Reiz

    Hi @simdevmon. I close this ticket because it works like expected. Having several project IDs in the project for each module is not a bad thing. It follows the principle of separation of concerns.

    If you followed the news you know that VersionEye is completely open source now: https://blog.versioneye.com/2016/06/28/versioneye-goes-open-source/.

    If you want you can implement another goal on the VersionEye Maven Plugin which implements your desired behavior. The current goal generates for each module a pom.json and sends it to the VersionEye API. The pom.json format is described here: https://github.com/versioneye/pom_json_format. The SBT and Gralde plugins are implementing it as well. You could iterate through all modules of a big Maven project and create only 1 pom.json file which contains the dependencies from all modules. That would be the desired behaviour for you. Looking forward to your pull request ;-)

  4. Simon Narkprasert reporter

    I found a workaround to add the project id for each sub-project in the maven pom file.

        <properties>
            <versioneye.projectId>56fa4b8a053a52000ac62ba8</versioneye.projectId>
        </properties>
    

    In this case I do not need a separate file for each sub project, but just an entry in the pom file, which is fine for me.

  5. Log in to comment