History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: QB-1438
Type: Bug Bug
Status: Resolved Resolved
Resolution: Won't Fix
Priority: Critical Critical
Assignee: Robin Shen
Reporter: Sten Rosendahl
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
QuickBuild

Impossible for a build to checkout to a branch with ClearCase SCM adapter

Created: 30/Oct/12 01:29 PM   Updated: 27/Dec/12 09:36 AM
Component/s: None
Affects Version/s: 4.0.41
Fix Version/s: None

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
Environment: Windows Server 2008 R2 Standard


 Description  « Hide
The ClearCase SCM adapter applies a hidden time rule to all config specs entered. This stops us from checking out files in a ClearCase branch, when trying ClearCase protests:

cleartool: Error: Element already has a branch of type "xyz" ("\main\xyz").
cleartool: Error: Unable to create branch requested by -mkbranch option in config spec.
cleartool: Error: Unable to check out "foo.c".

This is due to the fact that the ClearCase view isn't allowed to show something created after the starting time of the build due to the hidden time rule. This is in general a good thing when doing synchronized builds but in this case it is very troublesome. For example:

time mmm
element * CHECKEDOUT
element /myvob/... .../xyz/LATEST # Note that this LATEST rule has an implied rule "-time mmm" applied
element /myvob/... REL1 -mkbranch xyz
element /myvob/... /main/0 -mkbranch xyz
end time

Since the LATEST rule really points to a time before the checkout, the branch created by the checkout is not visible, hence ClearCase tries to create the branch twice causing an error.

We need rules which are exempted from the time directive, this would allow us to branch and modify files under source control during the build even in this QB releases. Typically, only files which are subject to change during the build should be exempted from the time rule. One crude way would be to make it possible to switch off the time rule all together (for non-synchronized builds). A suggested approach for synchronized builds would be to instead append the time rule to individual LATEST lines in the config spec, the ones not already having a time rule but only the ones having a -nocheckout option as the ones without that rule may be modified in the build; this would also make the change backward-compatible with how QB works today.



 All   Comments   Work Log   Change History      Sort Order:
Robin Shen [31/Oct/12 07:56 AM]
QB is designed to make sure that a single build operates against a particular revision of source, and does not expect the revision to be changed during the build; otherwise, the revision recorded in QB build will not be accurate to cause problems such as changes not being calculated accurately and build can not be reproduced exactly. I'd suggest to operate against a different view in your build script to work around this issue.