Issue Type: Bug Bug
Assignee: Unassigned
Components: cvs
Created: 19/Nov/12 9:36 PM
Description:

Is running 'rlog' after 'cvs up -r TAG' ok? Don't think so

If you are selecting 'Location' as Tag e.g.
Location : Tag
Tag Name : DEV
cvs commands run by Jenkins will be something like
cvs update -d -r DEV blah_module
cvs rlog -S -d'19 Nov 2012 11:43:30 +1100<19 Nov 2012 11:47:37 +1100' blah_module

What if the tag DEV on component/module has not moved but several versions are committed to cvs?

In this case what's happening is your workspace is not changed & still has got the old components with 'DEV' tag revisions however change log will show the committed changes 'cos of rlog.

I'll try to explain

1. Notice foo.bar 'DEV' tag is not at head
cvs log srcmgr/test/someDir/foo.bar | egrep 'head:|DEV:'
head: 1.15
DEV: 1.5

2. I committed a change
cvs commit -m 'test' srcmgr/test/someDir/foo.bar
Checking in srcmgr/test/someDir/foo.bar;
/cvs/srcmgr/test/someDir/foo.bar,v <-- foo.bar
new revision: 1.16; previous revision: 1.15

3. Notice that even though I have committed a change but my tag 'DEV' is not moved at all
cvs log srcmgr/test/someDir/foo.bar | egrep 'head:|DEV:'
head: 1.16
DEV: 1.5

4. Now my Jenkins settings is 'Location: tag', 'tag: DEV' & 'Update: ticked'
Run Jenkins
Building in workspace /export/home/amittal/temp
cvs update -d -P -r DEV srcmgr
cvs update: Updating srcmgr
cvs update: Updating srcmgr/adhoc
cvs update: Updating srcmgr/cm
cvs update: Updating srcmgr/cm/bin
cvs update: Updating srcmgr/logs
cvs update: Updating srcmgr/test
cvs update: Updating srcmgr/test/createSomeLongPathDirAveryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVerylongpathDirectory
cvs update: Updating srcmgr/test/someDir
cvs rlog -S -d19 Nov 2012 15:42:34 +1100<19 Nov 2012 15:51:08 +1100 srcmgr
cvs rlog: Logging srcmgr
cvs rlog: Logging srcmgr/adhoc
cvs rlog: Logging srcmgr/cm
cvs rlog: Logging srcmgr/cm/bin
cvs rlog: Logging srcmgr/logs
cvs rlog: Logging srcmgr/test
cvs rlog: Logging srcmgr/test/createSomeLongPathDirAveryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVerylongpathDirectory
cvs rlog: Logging srcmgr/test/someDir
[temp] $ /bin/sh -xe /var/tmp/hudson5023473001197182858.sh
+ pwd
/export/home/amittal/temp
Notifying upstream projects of job completion
Finished: SUCCESS

5. Jenkins displayed the committed change in the change log
Changes
Summary
test
amittal:
test
1.16 srcmgr/test/someDir/foo.bar
cat changelog.xml
<?xml version="1.0" encoding="UTF-8"?>
<changelog>
<entry>
<changeDate>2012-11-19 04:49:26</changeDate>
<author><![CDATA[amittal]]></author>
<file>
<name><![CDATA[srcmgr/test/someDir/foo.bar]]></name>
<fullName><![CDATA[/cvs/srcmgr/test/someDir/foo.bar]]></fullName>
<revision>1.16</revision>
</file>
<msg><![CDATA[test]]></msg>
</entry>
</changelog>

6. Now this is the problem what's happening here is since we are running 'cvs up -r DEV' and the tag DEV is not moved my workspace is still at old revision, no update (in this case 1.5)

cvs log srcmgr/test/someDir/foo.bar | egrep 'head:|DEV:'
head: 1.16
DEV: 1.5

However since we are running 'rlog' and a commit happened it shows that in change log whereas in my workspace there is no change to build. Therefore I think if we are running 'cvs up/co' with '-r TAG' option, running 'rlog' after that to determine change log for workspace is superfluous/not correct. As change log in this case should be determined by the TAG move not by commits.

Project: Jenkins
Priority: Major Major
Reporter: Akhil Mittal
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to