Advice on Component Structure
![]()
I've been playing in an RTC sandbox with source control & have been talking with some folks who have some experience with using RTC source control. Looking for some advice, but let's be clear -- I really don't know what I'm talking about! :)
Our product is a set of monitoring agents. Each agent has an independent set of source file, but there is also a "product level" set of files that includes build scripts, license files, common installer files, etc. The current code structure looks like this: /src/<component>/<component> buildScriptA buildScriptB buildScriptC where <component> indicates a specific agent or one of the product level things. For what I thing of as a component, each of the agents qualifies, because they have no dependency on the others and can be built independently. However, I was reading through a recent thread on this forum that suggests that components can be baselined independently -- and we really have no need to do that. I think this implies a single component is all we need. On the other hand, even though our code base isn't huge, it would be nice if individual agent developers could extract only their agent code from the repository -- so back to multiple components. But, I think this is the case (correct if wrong) that each RTC component has to map to an Eclipse project. So I puttered with changing the code structure to be: <component>/<component> placing a general .project file in each to make Eclipse happy. I can check in multiple projects, each in its own component. I'm still left with a set of common build files, some of which have to reside in the root directory. I don't know how to deal with these. I tried creating a .project in the root -- and I could import all these projects into an Eclipse workspace -- but even though the root project is a "parent" of the component projects, in Eclipse, they are all separate. I've no idea what happens if I try to check in such an overlapping set of projects with a parent-child relationship. Ideally, I'd like to be able to load the entire product from a stream, or let developers load just the components on which they are working. Not sure how to make this happen. A side question: As I puttered with this, I repeatedly created a repository workspace to learn how to load it, played, including creating new components, didn't like what I had and deleted the workspace. Lather, rinse, repeat....I now have a pile of duplicate components in the My Repository Workspaces > Components view with no apparent way to get rid of them or reuse them. Even when they were created in the context of one of my test workspaces, I don't think I could look at it in the Components view and figure out what its association to a workspace or stream was. What's up with this? Why can't I see any such association and why don't components that are created in the context of a workspace that is later deleted go away when no other workspace/stream uses them? I don't know what to do with multiple components with the same name, some of which might be "active" and others "deleted." Thanks! Chris |
5 answers
![]()
Geoffrey Clemm (30.1k●3●30●35)
| answered Dec 09 '10, 2:08 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
The reasons to have multiple components are primarily:
- wanting to baseline one tree independently of another tree - wanting to have different read-access to different trees. It appears that neither of these apply in your case, so one component is probably fine (and simplest). WRT just loading the files you need, when you "load" a component into your workspace, you are given a choice of loading everything or loading only certain folders. I believe that is simpler in your case than partitioning your source code into multiple components. WRT deleting components, no you cannot do that (yet, anyway). The best thing to do is to create a "junk" project area, and make that junk project area the owner of those components you don't want anymore. (In 3.0, you just right-click on the component, and select the "change onwer" command). Cheers, Geoff On 12/8/2010 8:23 PM, cbarlock wrote: I've been playing in an RTC sandbox with source control& have |
![]()
Can I reuse these "junk" components? I see that I can rename them, but it seems that I had to create new components when I created a new repository workspace -- leading to this proliferation of same-named components as I experimented.
Chris |
![]()
Geoffrey Clemm (30.1k●3●30●35)
| answered Dec 10 '10, 9:23 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Yes, you can re-use the junk components.
To avoid creating these gratuitous components, create your new workspaces against an existing stream, rather than "standalone". Cheers, Geoff On 12/10/2010 11:23 AM, cbarlock wrote: Can I reuse these "junk" components? I see that I can |
![]()
Well, at this point, there is no existing stream. I've got an empty sandbox in which I'm playing to learn how Jazz source control works.
Chris |
![]()
Geoffrey Clemm (30.1k●3●30●35)
| answered Dec 12 '10, 11:38 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
When you create a new project area, most of the project templates
(perhaps all of them?) will create an initial stream. You'll see it in the Source Control folder of your project area. And if you don't have one there, just right click on the Source Control folder, and create one with New->Stream. Then to create new workspaces, right click on that stream, and select New->Repository_Workspace. Cheers, Geoff On 12/12/2010 1:08 PM, cbarlock wrote: Well, at this point, there is no existing stream. I've got an empty |
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.