Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

DNG 7.02 Howto split large modules into several components with smaller modules

Hi,


we got a very large module (call it "A") and would like to split it into several smaller modules A<x>

- Each module A<x> shall be located in a separate component C<x>
- Incoming and outcoming links shall be preserved

We use GC.

We tried using "clone from", but cloning does not allow to include source part (component) into the GC of the destination (component), so no way to split it this way.

Any ideas how to do this?

DNG V7.02

0 votes



3 answers

Permanent link

 Hi Thomas,


Cloning wont work because two components owning the same cloned artifact can not be under the same global configuration.

Did you already try copying all the artifact between components first (including source parts) and later removing artifact from the modules that you do not need?

If I would be responsible for this I think I would go this way first.

0 votes

Comments

  Hi Bartosz,


thanks!

Yes I tried copying and removing (which simulates the move operation):

- but I want to preserve all incoming and outgoing links inbetween artifacts, even when they are located in different components after moving (copy/remove).

- This worked only in part: What worked was: in the destination the outgoing links into the source were ok, but not the incoming links, because they are not part of the copied artifacts and hence not copied. (In the source the outgoing links were just on the original, no additional outgoing links to the destination / copy.)

Do you have an idea how to "repair" / draw incoming links for the outgoing links? Or another different idea?

Best regards, 
Thomas 


Permanent link
Thomas,

The best practice for this is to make sure the original component configuration is not used in the GC after the clone.  To do this, whatever is remaining in the module after split should also be cloned into a new component. In your GC, remove the original component configuration where you cloned from, and replace it with all the new component configurations from the split. You can then archive the original component and related configurations if necessary(I assume the component only has the one large module).

Amit Talwar

0 votes

Comments

 Hi Amit,


thanks!

basically that is what I try to do, but keeping the links and the cloning restrictions "break my neck". I will illustrate:

Say we have Module A and B and have links from A to B and vice versa. In component SOURCE.
Module A will go into component DEST_A and module B into component DEST_B.

Tasks to accomplish:
Step 1: Clone module A into comp DEST_A. Then remove module A from SOURCE.
Step 2: Clone module B tino comp DEST_B. Then remove module B from SOURCE.

GC : with alle components, otherwise links will be lost.

Already Step 1 will not be able to clone, because gc would include module A twice (in source and destination).  And doing without gc links will break. 

Thomas






Thomas,
Based on your feedback, the source component has more than just the original module, is that correct?  If so, then you will need to clone everything except the cloned target components(i.e. module A and module B) from the source component into a new component.  Then build your GC with all the new component configurations.  If you want some additional help, please contact me via email at atalwar@us.ibm.com and we can setup a web meeting and I can give you more guidance.

 Hi Amit,


thanks for offering additional help. 

 "more than just the original module, is that correct?" --> no.

So I would like to clarify on our situation:

in the source component, initial situation is one very large module.

My idea was to: 

Step 1: split this large module first into smaller modules A, B, ... in the source (component) first. Links will be kept.

Step 2: move the smaller modules A, B, ... into other components (one component for each small module, Comp_A, ...)
- by cloning/removing each module A, B, ... one after another. (Incoming and outgoing links will be kept, across components)

This does not work, because modules except the one actually under clone/move is located in the source. Cloning impossible.


 

I follow step 1 and step 2.  After step 2, are you changing the GC and removing the original source configuration and replacing it with the 2 new target configurations?

 Hi,


I cannot even perform step 2:

My GC has the source component and destination component(s) included (because of the linking issue)

When I now try to clone from source component, module A to a destination component, this is prevented by the cloning dialog: 

Klonen Sie keine Artefakte zwischen zwei Komponenten, die sich in derselben globalen Konfiguration befinden (werden).

Globale Konfigurationen dürfen keine verschiedenen Komponenten aufweisen, die Versionen desselben Artefakts enthalten.
--> Do not clone artitfacts inbetween components, which are/will be in the same global configuration. Global configurations may not have different components with versions auf the same artifacts.

.. and that would be the case when cloning one module from source to destination.

 

I suggest we get on a web session, as I think you need to see the process for accomplishing your use case.  I know this is possible as I have done it in the past.  Please email me and let me know a time that you are available.

 ok, I am going to contact you by  atalwar@us.ibm.com


Had a call with Amit (Thanks!): Solution below ... 

in the source component, initial situation is one very large module.


Step 1: split this large module first into smaller modules A, B, ... in the source (component) first. Links will be kept.

Step 2: move the smaller modules A, B, ... into other components (one component for each small module, Comp_A, ...)
- by cloning/removing each module A, B, ... one after another. (Incoming and outgoing links will be kept, across components)

Step 2: This does not work, because modules except the one actually under clone/move is located in the source. Cloning impossible. 

==> Solution: 
- Do not include the target component into the global config, so cloning is possible.
- Do the cloning for all modules into their new components
- Then make up a global config which holds alle new components

- Important: All the incoming and outgoing links are there / restored, despite cloning was done outside of global config.


I disagree with this approach.   The streams of all of the new components should be in a global stream, so that the system prevents you from making the mistake of cloning a single artifact to more than one of your components.   This warning will only occur if the streams of all of your new components have been added to a global stream before you start the cloning process.   Please see my answer for the recommended approach.

showing 5 of 9 show 4 more comments

Permanent link
To split up a component X:in GC Y :
1. Split up your module in component X into the appropriate number of smaller modules (where an artifact must only appear in modules that will be assigned to the same component).
2. If the contribution from component X in GC Y is a stream, create a baseline of that stream of X.
3. Remove the contribution of component X from GC Y
4. Create the new components 
5. Add a stream of each new component as a contribution to GC Y
6. For each of the new component stream contributions to GC Y, clone the desired modules from the baseline of component X to that stream.

I expect that you neglected to perform step 3.

0 votes

Comments

@geoff, should there be a best practice FAQ?

Yes :-) 

Your answer

Register or log in 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 12,019

Question asked: Jul 19 '21, 8:04 a.m.

Question was seen: 1,403 times

Last updated: Jul 20 '21, 12:33 p.m.

Confirmation Cancel Confirm