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

Server-Side Advisor execution superceded

I am using the RTC 6.0.3 server-sdk. 

I have a Server-Side Advisor that prevents a parent-child relationship, between two work items, from being established. 

In my testing, I noticed that I can get the link to be established in spite of my Advisor. 

The following steps seem to interrupt the operation of my Advisor:

In the Select Work Items dialog box where you can select an existing work item, there is a hyperlink just above the OK and Cancel buttons.  Click this link:  Create Linked <INSERT WORK ITEM NAME HERE>

If you select this to create a linked Work Item, it will open up a New Work Item form for what ever type of Work Item was selected.  If the user fills out this form and saves the work item the link is established. 

Now go back to the original Work Item and update any field.  The advisor now prevents the save operation because there is a link that is not permitted by the Advisor. 

Is there a way to prevent this link from being established?

Do I need to create an advisor for the Create Linked Work Item operation and if so what is the Extension Point?

0 votes

Comments

I was able to create logic in my advisor to prevent any kind of links that are unwanted so at least in my project this defect is not impacting us because the improperly linked work items are not able to be created. 


Accepted answer

Permanent link

 I would consider this a defect. There are link operations that are not triggering the operational behavior, but that are not parent change, that are OSLC links.

Ryan McFadden selected this answer as the correct answer

0 votes

Comments

As stated above in my comment, I was able to safe-guard against this defect by not allowing improperly linked work items from being created and thus preventing this faulty behavior from impacting my project.

I will leave it to you to follow up with this defect and get the fix into a future release.

Hi Ryan,

If the UI provides the capability to create links and you are able to prevent the save with a pre condition, then that is as designed.

If you want/expect a different behavior or think something is wrong, you can create defects and enhancement requests. A forum entry is not considered a defect or enhancement request and forum members are not ER/PMR proxies.


One other answer

Permanent link

I was not able to use the advisor to prevent the link from being established.  My advisor only prevents a subsequent save operation from completing now that the link was able to be established.  


For example, if I have a work Item of TASK that can only be a child to a USER STORY work item.  If I have another DEFECT work item that I am editing and I set the TASK as a child to my DEFECT.  If there is nothing in my advisor  to block the save of the DEFECT there is no Save operation being executed on the TASK so the save completes successfully. 

Now the next time the TASK is updated and a save operation is attempted, the Advisor prevents the save because now there is Defect linked as a Parent and the only acceptable parent type is USER STORY.  The user will have to remove the errant link type before the TASK is able to be updated.  

The point is from the Source, the pre-condition is able to prevent the undesired link from being established.  It is on the destination record that the link is able to be established without a save operation on the destination record.  

This seems to be errant behavior.  

0 votes

Comments

As far as I can tell, the operation data in a work item save pre-condition provides several methods to access link information for before and after the save. This should allow to detect the issue before the save.


If both ends are changed, for each a pre-condition should be called.

Note: This only works for Work Item links such as parent/child. CLM links between applications and repositories can not be protected this way.  

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,951
× 27

Question asked: May 14 '18, 5:42 p.m.

Question was seen: 2,347 times

Last updated: May 15 '19, 1:24 a.m.

Confirmation Cancel Confirm