API to load projects in a component into a workspace
![]()
I can add a component to a workspace using IScmService#addComponent().
I can also use addComponentFromWorkspace() in order to specify a source workspace to load the component from. However, in either case, the projects in the component are not loaded into the newly added component. I can't seem to find a way to load existing projects in a component when we add the component in a new workspace. Will appreciate any help on this. Thanks! Debdoot |
4 answers
![]()
Geoffrey Clemm (30.1k●3●30●35)
| answered Jul 08 '10, 11:51 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
It depends on what you mean by "load" and "workspace".
There are "repository workspaces" (objects in the RTC repository) and "Eclipse workspaces" (which know about places on local disk where files are loaded ... commonly we call those places on disk where files are loaded a "sandbox"). Normally, we use the term "load" to describe the operation that copies files from the repository workspace into the sandbox (i.e. onto local disk). I'm guessing you aren't using "load" in that way, but rather are talking about how to specify the configuration of your repository workspace. To have specific configuration of a component in your repository workspace, you would want to select a specific baseline of that component to add to the workspace. If that is what you want, then we can get one of the RTC SCM API developers/users help you with what routines to call. Cheers, Geoff On 7/8/2010 8:53 AM, debdootm wrote: I can add a component to a workspace using |
![]()
Thanks Geoff for your reply and sorry for using improper terminology. Let me clarify.
I indeed wish to have a specific configuration of a component loaded into a repository workspace by using server side Java APIs. I use IScmService#addComponentFromWorkspace for this purpose. Next, I invoke IScmService#activeChangeSets to query for all change sets and accept them, so that I can get the latest files for the component in my repository workspace. However, on running this code I can't seem to find the configuration set in the workspace. Also, I dont get any change sets although I am sure there exist incoming changes. I had a chat with Heather (from Jazz SCM team) and she suggested use of IWorkspaceConnection in scm.client package. However, I shall prefer not to write a client since I am writing a server side utility and cannot get a handle to a TeamRepository. Please confirm whether what I am doing is correct or suggest alternatives Thanks for your help Debdoot It depends on what you mean by "load" and "workspace". I can add a component to a workspace using |
![]()
Geoffrey Clemm (30.1k●3●30●35)
| answered Jul 08 '10, 8:57 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Hi Debdoot,
I'm not familiar with the RTC SCM server-side API, so we'll need the Jazz SCM engineers to chime in on the details there. But logically, the first thing you have to ask yourself is what is the source for the component configuration that you want? There can be an arbitrary number of streams and workspaces and baselines that have different configurations of that component. Once you know where you want to get your configuration from, the RTC SCM team should be able to point you at what part of the API to use. Cheers, Geoff On 7/8/2010 2:08 PM, debdootm wrote: Thanks Geoff for your reply and sorry for using improper terminology. |
![]()
As Geoff indicated, you need to have a seed configuration that contains
the folders you want (the term project means something totally different in the context of server operations so we just tend to talk about files and folders). The seed can either be another workspace or a baseline. There are calls on the SCM service for both types of seeds (addComponentFromBaseline, addComponentFromWorkspace) and there is a newer API method for batching component operations (updateComponents). Does your seed workspace contain the folders you want added? Michael Geoffrey Clemm wrote: Hi Debdoot, |
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.