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

RTC API - linking changesets to workitems on deliver - serverside

Hi,

I'm trying to link workitems to changesets in an operation participant on a deliver but I'm getting this problem:

Links of this type may only be modified by the defining component.
    Link Type: com.ibm.team.filesystem.workitems.change_set
    Defining Component: com.ibm.team.filesystem.workitems
    Requesting Component: testparticipant.extensionService2

using the method at https://jazz.net/forum/questions/82384/serverside-create-link-from-a-workitem-to-a-changeset

And when trying a different approach I ran into a very similar problem that looked something like this

Links of this type may only be modified by the defining component.
    Link Type: com.ibm.team.filesystem.workitems.change_set
    Defining Component: com.ibm.team.filesystem.workitems
    Requesting Component: com.ibm.team.workitem          

except I'm unsure about what the last line looked like. If it helps It was caused in the saveWorkItem2 method of the WorkItemServer class.

You can find the second method here:

rsjazz.wordpress.com/2012/09/20/the-rtc-workitem-server-link-api-linking-to-work-items-and-other-elements/

From the looks of it I need to use a method in the 'Defining component' in order to the save the link. But I'm clueless as to how I would go about getting access to this component.

I tried the scm service

IScmService scmService = getService(IScmService.class);

but the CreateLinks method says that it is "experimental" when highlighted.

Any help is appreciated.

Thanks!.

RTC:4.0.7

0 votes



One answer

Permanent link
As described in https://rsjazz.wordpress.com/2014/12/03/creating-custom-link-types-for-rational-team-concert/ a component can request a link type to be exclusively usable by the defining component.

If you try to create that specific link type and the component ID you bind your extension to is not the one of that defining component, the API will refuse to create the link.

1 vote

Comments

Hi Ralph,

"If you try to create that specific link type and the component ID you bind your extension to is not the one of that defining component, the API will refuse to create the link"

I'm doing this in an operation participant. Binding an extension to a component ID is either a new concept to me, or perhaps I'm just not used to the terminology.

So is there a service that I can use to create this link? How can I be explicit about the component to which I'm binding my extension service?

Components are described in the Extension Workshop. See https://jazz.net/library/article/1000 . A component is basically a plugin that registers an ID. Other plugins declare the component they belong to using this ID.

Usually you declare your own component ID e.g. to be able to see your component got loaded. However, you can limit some operations to a component e.g. creation of links. In that case, if some extension does changes and that does not declare to be part of the component that is allowed to do changes, the changes are prevented.

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
× 10,941

Question asked: Jan 30 '15, 5:05 p.m.

Question was seen: 4,122 times

Last updated: Feb 03 '15, 1:48 a.m.

Confirmation Cancel Confirm