B & C can't be done (reliably) concurrently. One solution that we came up with was to reverse the priorities of the ccnet projects. This basically means that a check-in to something earlier in the dependency chain preempts the build chain, (so the project at the very end of the chain, 'D' in the example, might not end up getting built until everyone stops checking stuff in). Though not ideal, at least this guarantees all projects get built in the correct order - we want to avoid a queue that has B-A-D, which is bad :-).
Cheers, Carl. On Wed, Jul 1, 2009 at 4:20 PM, Craig<[email protected]> wrote: > > Hi Carl, > > Interesting challenge. I don't think CC.NET has anything that can > handle this at the moment. There is the force build publisher (http:// > confluence.public.thoughtworks.org/display/CCNET/ForceBuildPublisher), > but I'm not sure this would handle your scenario either > > If B & C can build concurrently, then you could put them in their own > queues and use the lockqueues element on the queues (http:// > confluence.public.thoughtworks.org/display/CCNET/Queue+Configuration) > to prevent A & D's queue from starting when either B or C is building. > Unfortunately, you couldn't put B & C in the same queue and use this > functionality, because it is not possible to guarantee which force > build would trigger first. The other side effect, especially with a > more complex scenario, is you would start to get a large number of > queues :-( > > > Craig > > On Jul 1, 2:06 pm, Carl Cerecke <[email protected]> wrote: >> What is the best way to ensure project dependencies in the shape of a >> diamond are built in the correct order? >> >> For example D depends on both B and C, and B and C both depend on A. >> >> Using the advice >> onhttp://confluence.public.thoughtworks.org/display/CCNET/Integration+Q... >> doesn't work: >> >> If A B C D all share a queue, and priorities are D > C = B > A (so D >> is a higher priority; i.e. a lower priority number), then after A >> builds, B and C will be put on the queue, but after B (say) finishes, >> it forcebuilds D which jumps in front of C. >> >> What would be ideal is to simply specify dependencies between >> <project>s and have ccnet automatically create integration queues for >> sets of disjoint acyclic project-dependency digraphs, including >> automatically handling forcebuilds, to ensure dependencies are >> correctly applied. >> >> Having to handle it manually with priorities seems error-prone and, as >> far as I can tell, not able to handle the diamond dependency problem. >> Feel free to correct me though! >> >> Our project-dependency graph is quite a bit more complicated than a >> simple diamond, so a general approach to the dependency problem would >> be better than a hack for the 4-project diamond special case. >> >> Cheers, >> Carl. >> -- >> Carl Cerecke >> GeoBase Senior Software Engineer – Telogis >> Researchwww.telogis.com www.telogis.co.nz >> +1 949 625-4115 ext. 208 (USA) +64 3 339 2825 ext. 208 (NZ) >> >> Leading Global Platform for Location Based Services >> OnTrack and GeoBase enable over 350,000 vehicles and mobile devices >> worldwide. >> -- >> This e-mail, and any attachments, is intended only for use by the >> addressee(s) named herein and may contain legally privileged and/or >> confidential information. It is the property of Telogis. If you are >> not the intended recipient of this e-mail, you are hereby notified >> that any dissemination, distribution or copying of this e-mail, any >> attachments thereto, and use of the information contained, is strictly >> prohibited. If you have received this e-mail in error, please notify >> the sender and permanently delete the original and any copy there of. > -- Carl Cerecke GeoBase Senior Software Engineer – Telogis Research www.telogis.com www.telogis.co.nz +1 949 625-4115 ext. 208 (USA) +64 3 339 2825 ext. 208 (NZ) Leading Global Platform for Location Based Services OnTrack and GeoBase enable over 350,000 vehicles and mobile devices worldwide. -- This e-mail, and any attachments, is intended only for use by the addressee(s) named herein and may contain legally privileged and/or confidential information. It is the property of Telogis. If you are not the intended recipient of this e-mail, you are hereby notified that any dissemination, distribution or copying of this e-mail, any attachments thereto, and use of the information contained, is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the original and any copy there of.
