Why does Deletion of an Iteration programatically throw ProcessDataValidationException ?
Following is my code to delete iteration from a project area :
IIteration iter = null;
I am recieving the following error message : com.ibm.team.process.common.service.ProcessDataValidationException: Iteration 'FY14Q3' has a backpointer to timeline 'Project_Timeline', but the timeline does not contain it. An explanation about this error might be helpful. |
3 answers
It looks like your iteration is referencing a project timeline. Did you delete the project timeline that iteration was associated with?
Comments
Achla Sharma
commented Sep 04 '14, 5:13 a.m.
No, I just wanted to delete a particular iteration from the project timeline. The project timeline is not deleted. |
When you use IDevelopmentLine.removeIteration() to remove an iteration, you should also have to remove the reference of development line from the iteration that is about to be removed.
For example:
developmentLine.removeIteration(iteration);
iteration.setDevelopmentLine(null); Comments
Achla Sharma
commented Sep 04 '14, 5:12 a.m.
I tried implementing your suggestion. I am getting the following error message on save operation :
com.ibm.team.process.common.service.ProcessDataValidationException: timeline may not be null |
If you just want to delete a iteration, you can use com.ibm.team.process.client.IProcessItemService.delete(IProcessItemHandle, boolean, IProgressMonitor) on client site.
Comments
Achla Sharma
commented Sep 29 '14, 6:35 a.m.
Hi Thanks for the alternative. I tried using the method. The problem with this approach is that it renders the existent workitems using the iteration in an unstable state. Instead I tried this :com.ibm.team.process.client.IProcessItemService.archiveProcessItem(IProcessItemHandle, IProgressMonitor). It did archive the iteration still I was getting work items in an uunstable state. I just added the workingDevelopmentLine.remove operation after this and it worked for me. We now have unnecessary iterations archived. For the workitems using the iteration, the planned for field has value :"iteration-name"+"(archived)".
Achla Sharma
commented Sep 29 '14, 6:37 a.m.
The code now looks like this :
service.archiveProcessItem(working_Iteration, null);
workingDevLine.removeIteration(working_Iteration);
|
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.