It's all about the answers!

Ask a question

How can I import additional branches from base CC?


Jirong Hu (1.5k9295258) | asked Oct 25 '11, 4:29 p.m.
Hi All

https://jazz.net/library/article/50/#ftnt5

Following this article, I imported the main branch. e.g. labels (INITIAL, REL1 and REL2) were imported to RTC as baselines, by attaching an attribute call LabelHistoryImportor. The import process created a stream called INITIAL, and a component called BaseCC.

Now how can I import the REL2_bugfix branch? I did the following:
1. Created an attribute call LabelHistoryImportor2, and attached it to label REL2_BUGFIX1, REL2_BUGFIX2.
2. Run the import wizard again.

This created a new stream called REL2_BUGFIX1 and a new component called BaseCC. Means they are completely separate from the main branch. But I was expecting they should share the same component.

Can anyone help?

Below are the sample base CC info:
~~~~~~~~~~~~~~~~~~~~~

M:\admin_view\BaseCC>cleartool lsvtree triggers
triggers@@\main
triggers@@\main\1 (INITIAL)
triggers@@\main\2 (REL1)
triggers@@\main\3 (REL2)
triggers@@\main\REL2_bugfix
triggers@@\main\REL2_bugfix\1 (REL2_BUGFIX2, REL2_BUGFIX1)

M:\admin_view\BaseCC>cleartool lstype -kind lbtype -fmt "%n %a"
BACKSTOP CHECKEDOUT INITIAL LATEST REL1 (LabelHistoryImportor="1")REL2 (LabelHistoryImportor="2")REL2_BUGFIX1 REL2_BUGFIX2

M:\admin_view\BaseCC>cleartool lstype -kind lbtype -fmt "%n %a"
BACKSTOP CHECKEDOUT INITIAL LATEST REL1 REL2 REL2_BUGFIX1 (LabelHistoryImportor2="1")REL2_BUGFIX2 (LabelHistoryImportor2="2")
M:\admin_view\BaseCC>

5 answers



permanent link
Geoffrey Clemm (30.1k33035) | answered Oct 26 '11, 12:13 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
The component called BaseCC should have been re-used by the second import.
What makes you think they are two different RTC components?

Cheers,
Geoff

On 10/25/2011 4:38 PM, hujirong wrote:
Hi All

https://jazz.net/library/article/50/#ftnt5

Following this article, I imported the main branch. e.g. labels
(INITIAL, REL1 and REL2) were imported to RTC as baselines, by
attaching an attribute call LabelHistoryImportor. The import process
created a stream called INITIAL, and a component called BaseCC.

Now how can I import the REL2_bugfix branch? I did the following:
1. Created an attribute call LabelHistoryImportor2, and attached it to
label REL2_BUGFIX1, REL2_BUGFIX2.
2. Run the import wizard again.

This created a new stream called REL2_BUGFIX1 and a new component
called BaseCC. Means they are completely separate from the main
branch. But I was expecting they should share the same component.

Can anyone help?

Below are the sample base CC info:
~~~~~~~~~~~~~~~~~~~~~

M:\admin_view\BaseCC>cleartool lsvtree triggers
triggers@@\main
triggers@@\main\1 (INITIAL)
triggers@@\main\2 (REL1)
triggers@@\main\3 (REL2)
triggers@@\main\REL2_bugfix
triggers@@\main\REL2_bugfix\1 (REL2_BUGFIX2, REL2_BUGFIX1)

M:\admin_view\BaseCC>cleartool lstype -kind lbtype -fmt "%n
%a"
BACKSTOP CHECKEDOUT INITIAL LATEST REL1
(LabelHistoryImportor="1")REL2
(LabelHistoryImportor="2")REL2_BUGFIX1 REL2_BUGFIX2

M:\admin_view\BaseCC>cleartool lstype -kind lbtype -fmt "%n
%a"
BACKSTOP CHECKEDOUT INITIAL LATEST REL1 REL2 REL2_BUGFIX1
(LabelHistoryImportor2="1")REL2_BUGFIX2
(LabelHistoryImportor2="2")
M:\admin_view\BaseCC

permanent link
Jirong Hu (1.5k9295258) | answered Oct 26 '11, 11:46 a.m.
The component called BaseCC should have been re-used by the second import.
What makes you think they are two different RTC components?

Cheers,
Geoff


OK, I think I was wrong when I saw both components are having the same "Initial Baseline". I browsed the baselines, they are the same. So I guess they are the same component.

Now I am totally confused by this "Initial Baseline" in both streams (INITAIL and REL2_BUGFIX1).

1. Currently, both INITAIL and REL2_BUGFIX streams are with "Initial Baseline", right? This "Initial Baseline" should contains nothing, right? To confirm that, I right-click the "1: Initial Baseline" in the History view (right-bottom corner), Show Repository File. It's empty. But if I select the BaseCC (1:Initial Baseline) component within the stream, Show Repository File displays the files. Why?

2. I created two corresponding workspaces to both INITAIL and REL2_BUGFIX streams and loaded into sandbox. These two workspaces are with "Initial Baseline" as well, so they should have the contents same as their streams.

3. I compared workspace INITAIL to my base CC view looking at the \main branch latest (element * CHECKEDOUT element * /main/LATEST). They are the same.

4. I compared workspace REL2_BUGFIX to my base CC view looking at the \REL2_bugfix branch latest (element * CHECKEDOUT element * /main/REL2_bugfix/LATEST element * REL2 -mkbranch REL2_bugfix
). They are the same.

5. I replaced the REL2_BUGFIX workspace with the imported baseline lbtype:REL2_BUGFIX2@\BaseCC and do the same compare in Step4, they are the same.

6. I replaced the REL2_BUGFIX workspace with the imported baseline lbtype:REL2@\BaseCC and do the same compare in Step4, they are NOT the same.

Now I completely don't understand why the first time I do Step 3&4, there are the same.

1. Isn't "Initial Baseline" empty? Why I can see the latest file while the stream/workspace are at "Initial Baseline"?

2. How can I find out where are these imported baseline created? On which stream/workspace? I right-click the baselines in the History view, but the Baseline Info doesn't have this info. Why?!

3. Another thing I don't understand is the import wizard takes the backstop label as the stream name, which totally doesn't make sense. Why don't let's specify in the wizard? Now I have to figure out if the subsequent import will work if I rename the streams.

http://i40.tinypic.com/j64qiw.png

permanent link
Geoffrey Clemm (30.1k33035) | answered Oct 26 '11, 1:04 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Comments below

On 10/26/2011 11:53 AM, hujirong wrote:
gmclemmwrote:
The component called BaseCC should have been re-used by the second import.
What makes you think they are two different RTC components?

Cheers,
Geoff

OK, I think I was wrong when I saw both components are having the same
"Initial Baseline". I browsed the baselines, they are the
same. So I guess they are the same component.

OK, that's good. Then this is working as designed.

Now I am totally confused by this "Initial Baseline" in both
streams (INITAIL and REL2_BUGFIX1).

The "baseline" in a given stream does not represent the current state of
the stream, but rather the set of baselines that are in the "history" of
that stream. So all that is saying is that the only baselines in the
history of these two streams is the Initial_Baseline.

1. Currently, both INITAIL and REL2_BUGFIX streams are with
"Initial Baseline", right? This "Initial
Baseline" should contains nothing, right? To confirm that, I
right-click the "1: Initial Baseline" in the History view
(right-bottom corner), Show Repository File. It's empty. But if I
select the BaseCC (1:Initial Baseline) component within the stream,
Show Repository File displays the files. Why?

When you say "show repository files" in the stream, that shows the
current state of that stream (including all change sets that have been
delivered to that stream). Whereas "show repository files" on the
baseline show you the state of that baseline.

2. I created two corresponding workspaces to both INITAIL and
REL2_BUGFIX streams and loaded into sandbox. These two workspaces are
with "Initial Baseline" as well, so they should have the
contents same as their streams.

Same as above. This just says that the only baseline in the history of
this workspace is the Initial_Baseline. But the current state of the
workspace is that baseline plus any subsequent change sets. Note: A new
workspace is initialized with a copy of the history of the stream upon
which it is based. So it doesn't start out with "empty" history.

3. I compared workspace INITAIL to my base CC view looking at the
\main branch latest (element * CHECKEDOUT element * /main/LATEST).
They are the same.

Good. Then the import worked.

4. I compared workspace REL2_BUGFIX to my base CC view looking at the
\REL2_bugfix branch latest (element * CHECKEDOUT element *
/main/REL2_bugfix/LATEST element * REL2 -mkbranch REL2_bugfix
). They are the same.

Good. Then that import also worked.

5. I replaced the REL2_BUGFIX workspace with the imported baseline
lbtype:REL2_BUGFIX2@\BaseCC and do the same compare in Step4, they
are the same.

Good. Then that worked as well.

6. I replaced the REL2_BUGFIX workspace with the imported baseline
lbtype:REL2@\BaseCC and do the same compare in Step4, they are NOT
the same.

That is just saying that the REL2_BUGFIX configuration is not the same
as the REL2 configuration. Whereas in step 4, you checked whether
REL2_BUGFIX in RTC was the same as REL2_BUGFIX in CC ... which they
should be. So the step 6 comparison is unrelated to the step 4 comparison.

Now I completely don't understand why the first time I do Step
3&4, there are the same.

1. Isn't "Initial Baseline" empty? Why I can see the latest
file while the stream/workspace are at "Initial Baseline"?

Because this display was just telling you that Initial_Baseline was in
the history of the stream, not that it is the current configuration of
the stream.

2. How can I find out where are these imported baseline created? On
which stream/workspace? I right-click the baselines in the History
view, but the Baseline Info doesn't have this info. Why?!

This baselines are not created on the synchronization stream ... they
are just stored in the component (in the current implementation, they
are created in the CLONE workspace, but that is just an implementation
detail that can change).

3. Another thing I don't understand is the import wizard takes the
backstop label as the stream name, which totally doesn't make sense.
Why don't let's specify in the wizard? Now I have to figure out if
the subsequent import will work if I rename the streams.

You are always free to rename the synchronized stream. Subsequent
imports will work fine.

Cheers,
Geoff

permanent link
Jirong Hu (1.5k9295258) | answered Oct 26 '11, 4:48 p.m.
OK, I think the key to understand this is "only baselines in the history of these two streams is the Initial_Baseline", that's why the stream shows the component baseline as Initial_Baseline, simply because that's the latest baseline in the stream, and that's the foundation of the stream.

1. Now I don't understand why you don't keep/deliver/whatever these imported baselines such as lbtype:REL2_BUGFIX2@\BaseCC in the new stream? I kind of understand it's not necessary because even I delete the CLONE stream, these baselines are still there. But people like to see these imported baselines in the new stream?

Or let me ask another question:

2. For sure we don't want to use the new stream name created by the import wizard. So what's the best practice, shall I rename them, or create a new stream to include the component? I assume even I create a new stream, I still can re-do the import with the old sync stream, because they still import into the same component.

Thanks a lot for your help. I am ready to do the real import now.

Jirong

permanent link
Geoffrey Clemm (30.1k33035) | answered Oct 26 '11, 6:31 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
1. There is an edge case why we don't. Suppose you imported a few
baselines from CC to the synchronized stream, and then you delivered
some changes in RTC to that stream and created some baselines in the
process, and then you imported a few more baselines. The second set of
imported baselines cannot be applied to the synchronized stream, because
of the intervening change sets. So rather than having only some
baselines show up and not others, we felt it simplest to just have none
show up. But please feel free to submit a work item, if you'd like to
see that behavior changed.

2. You should just rename the sync stream to whatever you want it to be.
That's why we didn't add that field to the wizard, because the "rename"
operation in RTC is so easy to invoke.

Hope the import goes well!

Cheers,
Geoff

On 10/26/2011 4:53 PM, hujirong wrote:
OK, I think the key to understand this is "only baselines in the
history of these two streams is the Initial_Baseline", that's
why the stream shows the component baseline as Initial_Baseline,
simply because that's the latest baseline in the stream, and that's
the foundation of the stream.

1. Now I don't understand why you don't keep/deliver/whatever these
imported baselines such as lbtype:REL2_BUGFIX2@\BaseCC in the new
stream? I kind of understand it's not necessary because even I delete
the CLONE stream, these baselines are still there. But people like to
see these imported baselines in the new stream?

Or let me ask another question:

2. For sure we don't want to use the new stream name created by the
import wizard. So what's the best practice, shall I rename them, or
create a new stream to include the component? I assume even I create
a new stream, I still can re-do the import with the old sync stream,
because they still import into the same component.

Thanks a lot for your help. I am ready to do the real import now.

Jirong

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.