Using Bamboo 4.1, we have a number of common artifacts building and deploying to our local maven repository server for use in dependent plans; eg. java-common and java-core plans produce java-common-SNAPSHOT and java-core-SNAPSHOT artifacts, for use in java-planA and java-planB.
However, when ABD is enabled against a central Git remote, the branch (say java-common-featurebranch) deploys the -SNAPSHOT again, resulting in a potentially incompatible -SNAPSHOT jar dropping to maven, and leading to downstream build issues.
Obviously, this _could_ be handled by enforcing policies in which branches are required to update the POM to reflect a different artifact handle, or by ensuring that downstream builds rely on non-SNAPSHOT artifacts, but both of these solutions seem creaky.
How does Atlassian, or any other group that sees this question handle situations like this? I figured I'd ask before filing an improvement request in JAC, since it seems like this can't be an uncommon situation, and someone may have a clever solution.
Ideas I've tossed around:
Anyone have better solutions? It seems like there's a couple open BAM issues that might start to lead to a solution, including BAM-10804, but there's still some definite magic that would have to occur inside Bamboo's mvn plugins to improve this.
How about specifying a different version for your maven project based on the branch name? With 4.2, we added the bamboo.branchName variable so passing the following to the Maven via the Goals field on the Maven task should work
-Dproject.version=${your_project_version}-${bamboo.branchName}-SNAPSHOT
You guys always seem to have a release that solves a need shortly after I find the need. Cheers!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Glad to hear it! Hope this works out for you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.