WorkItem not updated after saveWorkItem2(...)

I try to programmatically set the state of a workItem... based on API documentation, the right way would be to give an actionId to the saveWorkItem2 operation:
This works, and returns an OK status - however, it does not seem to work, e.g. the workitem is not updated with the new state afterwards..
Any ideas?
[...]
IWorkItemServer workItemService = getService(IWorkItemServer.class);
workItemService.saveWorkItem2(storyItemWorkingCopy, null, "some.resolve.action.id");
This works, and returns an OK status - however, it does not seem to work, e.g. the workitem is not updated with the new state afterwards..
Any ideas?
3 answers

I try to programmatically set the state of a workItem... based on API documentation, the right way would be to give an actionId to the saveWorkItem2 operation:
[...]
IWorkItemServer workItemService = getService(IWorkItemServer.class);
workItemService.saveWorkItem2(storyItemWorkingCopy, null, "some.resolve.action.id");
This works, and returns an OK status - however, it does not seem to work, e.g. the workitem is not updated with the new state afterwards..
Any ideas?
Are you saving the work item working copy after? so:
storyItemWorkingCopy.save(IProgressMonitor p)
If you are then without seeing the full code I'm not sure I can help

Thanks for the point... it seems that I'm somehow mixing Service- with Client side API?
Just to be clear - I'm inside a server-side workItem Participant, and not on the client side.
Therefore, I have only "Services" and noWorkItemWorkingCopy instance (and no save() method), and no IWorkItemWorkingCopyManager and such, which are part of the "client" API ... my "WorkingCopy" is of type IWorkItem .
All I have isIWorkItemCommon and IWorkItemServer and IRepositoryItemService
So perhaps I'm using some bad pattern here?
thanks for any hint...
Are you saving the work item working copy after? so:
If you are then without seeing the full code I'm not sure I can help
Just to be clear - I'm inside a server-side workItem Participant, and not on the client side.
Therefore, I have only "Services" and no
All I have is
So perhaps I'm using some bad pattern here?
thanks for any hint...
I try to programmatically set the state of a workItem... based on API documentation, the right way would be to give an actionId to the saveWorkItem2 operation:
[...]
IWorkItemServer workItemService = getService(IWorkItemServer.class);
workItemService.saveWorkItem2(storyItemWorkingCopy, null, "some.resolve.action.id");
This works, and returns an OK status - however, it does not seem to work, e.g. the workitem is not updated with the new state afterwards..
Any ideas?
Are you saving the work item working copy after? so:
storyItemWorkingCopy.save(IProgressMonitor p)
If you are then without seeing the full code I'm not sure I can help