quattor / maven-tools

Maven-based Build Tools
www.quattor.org
Apache License 2.0
4 stars 13 forks source link

package-build-scripts: chicken&egg problem during release #85

Closed jouvin closed 8 years ago

jouvin commented 8 years ago

During 1.49 release of the build-tools, I faced a problem because package-build-scripts has a parent pom version which is updated during the release process prepare phase to the next snapshot (as it is always done). But during the verify phase, package-build-scripts needs to access its parent which is not yet available... I remember reading in Maven documentation that verify phase should not depend on things done during the test phase or later... I managed to work around the problem by:

The chicken&egg problem must be reviewed to solve this release issue. It can be tested first by executing the verifyphase, then by doing a release:prepare and cancel/revert it when it begins to ask for the GPG keys (the problem happens before).

jouvin commented 8 years ago

I am not sure what package-build-scripts does. Depending on this, one solution would be to disable it at release time in the same way as this is done for cfg-module-dist...

stdweird commented 8 years ago

@jouvin package-build-scripts allows us to create an rpm with the Test::Quattor tools, so you can run the unittests without maven. in that sense, feel free to skip it in the build-tools release process. rpms will/should be created during the regular quattor release process.

jouvin commented 8 years ago

After thinking more about this issue, I reopen this issue. I think #87 is just a workaround for 2 reasons:

In addition, it is necessary to check that package-build-scripts/pom.xml run successfully when not called by the main pom.xml (I guess so...).

An alternative could be to have a separate repo for package-build-scripts if we manage to import the Test::Quattor code at build time. Could a git submodule help with this?

stdweird commented 8 years ago

hmmm, wrt the second repo, all the code required for the rpm is pulled in via the maven dependecy on build-scripts. so it would be a repo with just one pom.xml, we could definitely try that.

jouvin commented 8 years ago

In this case, this is particularly easy and would make the build much cleaner... If this is just one pom.xml we could also see if we can put it in the release repo but I am afraid that we may be back to the original problem... To be checked, I don't remember if there is already a pom.xml in the release repo.

jrha commented 8 years ago

Discussed at workshop and decided to close as the original issue is solved, but may be suboptimal. We can open a new issue to discuss this if it becomes a problem.