It's all about the answers!

Ask a question

Can a build deliver a change back into source control?(Long)


Chris Melikian (6672) | asked Oct 22 '08, 4:19 a.m.
I have a project which contains dependencies. So I have:-

SomePortlet
..relies on..
DomainModel
..relies on..
ExternalComponents

Each of these are separate Eclipse projects and each has an Ant build file. Each project/build file is an RTC Component and produces a set of files (JARs) which I would like to put into source control.

I know there's a 10MB limit on individual files but I'm going to get around that by not compressing the JARs but keeping them in a folder and putting that into source control so the deltas between changes should be much much less.

Question is, can I put my artifacts into source control using Ant? The artifactFilePublisher task looks good but where does it publish it to and how do I make that available to other builds?

These built component JARs are going to be used as libraries in the build path of these Eclipse Java projects so they need to be accessible within the Eclipse workspace. They could be outside but I want them source controlled so they should be within Eclipse.

I have coded my Ant scripts so that they work with standalone (not Personal) builds and they place components into an "Artifacts" project which is also source controlled. I would like the team concert build to also publish the "team build" components to the same location under Artifacts in the Project Stream. In this way developers can work on their local builds and then deliver their source code when they believe it is right to share the code. However developers would not be able to check into the "team build" locations as they could potentially bypass the tests which the build runs.

I'm not sure whether Team Concert can support the type of build that I'm trying to create. I've built this successfully using other CI tools and would like to get it also working with Team Concert as it is potentially brilliant with it's full end-to-end integration.

Any help appreciated.

Cheers, Chris.

4 answers



permanent link
Chris Melikian (6672) | answered Oct 22 '08, 4:45 a.m.
Just thinking... maybe I could use Subversion as the SCM within Team Concert. Then I can use the SVN Ant tasks to deliver my code?

permanent link
Chris Melikian (6672) | answered Oct 22 '08, 5:39 a.m.
Just thinking... maybe I could use Subversion as the SCM within Team Concert. Then I can use the SVN Ant tasks to deliver my code?

Looking into this it's better to keep the source within RTC SCM. I'm now thinking of a hybrid approach where source is in Jazz and binaries in SVN where the RTC team build commit the binaries into SVN and tag the commit with the build UUID from RTC therefore maintaining a link between builds.

It would mean maintaining two SCMs but there would be little maintenance needed for SVN. SVN could be locked down so binaries could only be generated by the team builds ensuring (a little) security.

Still interested in your thoughts! :-)

permanent link
Chris Melikian (6672) | answered Oct 22 '08, 6:17 a.m.
OK, so there is a command-line tool called scm which looks like it will do the job. It's a shame there is no Ant task for this as executing an OS command in Ant makes for quite messy code, but at least we have something! :-)

permanent link
Jean-Michel Lemieux (2.5k11) | answered Oct 24 '08, 3:36 a.m.
JAZZ DEVELOPER
I have a project which contains dependencies. So I have:-

SomePortlet
..relies on..
DomainModel
..relies on..
ExternalComponents

Each of these are separate Eclipse projects and each has an Ant build file. Each project/build file is an RTC Component and produces a set of files (JARs) which I would like to put into source control.

I know there's a 10MB limit on individual files but I'm going to get around that by not compressing the JARs but keeping them in a folder and putting that into source control so the deltas between changes should be much much less.

Question is, can I put my artifacts into source control using Ant? The artifactFilePublisher task looks good but where does it publish it to and how do I make that available to other builds?


It's actually a 1GB limit, so adding 10MB jar isn't a problem. When you publish an artifact during the build process, it's available via the build result editor in the RTC client.


These built component JARs are going to be used as libraries in the build path of these Eclipse Java projects so they need to be accessible within the Eclipse workspace. They could be outside but I want them source controlled so they should be within Eclipse.

I have coded my Ant scripts so that they work with standalone (not Personal) builds and they place components into an "Artifacts" project which is also source controlled. I would like the team concert build to also publish the "team build" components to the same location under Artifacts in the Project Stream. In this way developers can work on their local builds and then deliver their source code when they believe it is right to share the code. However developers would not be able to check into the "team build" locations as they could potentially bypass the tests which the build runs.

I'm not sure whether Team Concert can support the type of build that I'm trying to create. I've built this successfully using other CI tools and would like to get it also working with Team Concert as it is potentially brilliant with it's full end-to-end integration.

Any help appreciated.

Cheers, Chris.


You should be able to use the command line client to check-in / deliver the artifacts during the build. We would like to provide more ant tasks to make this easier, but that won't be until the next feature release.

Jean-Michel

Your answer


Register or to post your answer.