It's all about the answers!

Ask a question

Saving work item results in Long-running op prohibited msg


Anthony Krowiak (11111612) | asked May 18 '09, 12:20 p.m.
I am trying to change the workflow state of a work item via the following methods:

WorkItemWorkingCopy.setWorkflowAction(String)
WorkItemWorkingCopy.save(null)

The exception below is logged to stdout. Why is this message being logged when ThreadCheck.prohibitLongOps() is never called by my code and the system property "disallow.server.ops.on.ui.thread" is NOT set?



Throwable occurred: java.lang.IllegalStateException: Long-running operations prohibited on this thread
at com.ibm.team.repository.client.util.ThreadCheck.checkLongOpsAllowed(ThreadCheck.java:117)
at com.ibm.team.repository.client.internal.ServiceInterfaceProxy.invoke(ServiceInterfaceProxy.java:81)
at $Proxy0.fetchOrRefreshItems(Unknown Source)
at com.ibm.team.repository.client.internal.ItemManager$5.run(ItemManager.java:1408)
at com.ibm.team.repository.client.internal.ItemManager$5.run(ItemManager.java:1)
at com.ibm.team.repository.client.internal.TeamRepository$3.run(TeamRepository.java:1129)
at com.ibm.team.repository.common.transport.CancelableCaller.call(CancelableCaller.java:76)
at com.ibm.team.repository.client.internal.TeamRepository.callCancelableService(TeamRepository.java:1122)
at com.ibm.team.repository.client.internal.TeamPlatformObject.callCancelableService(TeamPlatformObject.java:41)
at com.ibm.team.repository.client.internal.ItemManager.internalFetchItems(ItemManager.java:1403)
at com.ibm.team.repository.client.internal.ItemManager.access$2(ItemManager.java:1362)
at com.ibm.team.repository.client.internal.ItemManager$AbstractStore.retrieveItems(ItemManager.java:214)
at com.ibm.team.repository.client.internal.ItemManager$CurrentStore.fetchItems(ItemManager.java:347)
at com.ibm.team.repository.client.internal.ItemManager.fetchPartialItems(ItemManager.java:935)
at com.ibm.team.workitem.client.internal.AuditableClient.resolveAuditables(AuditableClient.java:145)
at com.ibm.team.workitem.common.internal.WorkItemCommon.findAttributes(WorkItemCommon.java:297)
at com.ibm.team.workitem.client.internal.WorkItemClient.findAttributes(WorkItemClient.java:475)
at com.ibm.team.workitem.client.internal.WorkItemClient$DependencyCache.findDependents(WorkItemClient.java:126)
at com.ibm.team.workitem.client.internal.WorkItemClient.findDependents(WorkItemClient.java:488)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.fireWorkItemChanged(WorkItemWorkingCopyRegistry.java:1205)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.fireWorkItemChanged(WorkItemWorkingCopyRegistry.java:1179)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.access$0(WorkItemWorkingCopyRegistry.java:1175)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry$InternalListener.featureChanged(WorkItemWorkingCopyRegistry.java:315)
at com.ibm.team.workitem.common.internal.util.EMFListener.notifyChanged(EMFListener.java:36)
at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:247)
at com.ibm.team.workitem.common.internal.model.impl.WorkItemImpl.setInternalState(WorkItemImpl.java:999)
at com.ibm.team.workitem.common.internal.model.impl.WorkItemImpl.eSet(WorkItemImpl.java:2378)
at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjectImpl.java:1061)
at com.ibm.team.workitem.common.internal.util.EMFHelper.merge(EMFHelper.java:131)
at com.ibm.team.workitem.common.internal.util.EMFHelper.merge(EMFHelper.java:70)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.remoteUpdate(WorkItemWorkingCopyRegistry.java:772)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.access$14(WorkItemWorkingCopyRegistry.java:748)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry$8.run(WorkItemWorkingCopyRegistry.java:1683)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry$8.run(WorkItemWorkingCopyRegistry.java:1)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyImpl$1.run(WorkItemWorkingCopyImpl.java:410)
at com.ibm.team.repository.client.util.ThreadCheck.runProhibitingLongOps(ThreadCheck.java:173)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyImpl.run(WorkItemWorkingCopyImpl.java:404)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyImpl.write(WorkItemWorkingCopyImpl.java:399)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.saveWorkItems(WorkItemWorkingCopyRegistry.java:1681)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.saveAffected(WorkItemWorkingCopyRegistry.java:1560)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.save(WorkItemWorkingCopyRegistry.java:1461)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyRegistry.save(WorkItemWorkingCopyRegistry.java:1432)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyManager.save(WorkItemWorkingCopyManager.java:115)
at com.ibm.team.workitem.client.internal.WorkItemWorkingCopyImpl.save(WorkItemWorkingCopyImpl.java:221)
at com.ibm.ArtifactTechnology.ABS.performers.RTC.UpdateAction.testGetActions(UpdateAction.java:459)
at com.ibm.ArtifactTechnology.ABS.performers.RTC.UpdateAction.main(UpdateAction.java:550)

2 answers



permanent link
Patrick Streule (4.9k21) | answered May 18 '09, 2:05 p.m.
JAZZ DEVELOPER
I am trying to change the workflow state of a work item via the
following methods:

WorkItemWorkingCopy.setWorkflowAction(String)
WorkItemWorkingCopy.save(null)

The exception below is logged to stdout. Why is this message being
logged when ThreadCheck.prohibitLongOps() is never called by my code
and the system property "disallow.server.ops.on.ui.thread"
is NOT set?

By default, the thread check is always done. I would strongly recommend to
perform any server-communication in a background job.

--
Regards,
Patrick
Jazz Work Item Team

permanent link
Anthony Krowiak (11111612) | answered May 19 '09, 3:41 p.m.
I am trying to change the workflow state of a work item via the
following methods:

WorkItemWorkingCopy.setWorkflowAction(String)
WorkItemWorkingCopy.save(null)

The exception below is logged to stdout. Why is this message being
logged when ThreadCheck.prohibitLongOps() is never called by my code
and the system property "disallow.server.ops.on.ui.thread"
is NOT set?

By default, the thread check is always done. I would strongly recommend to
perform any server-communication in a background job.

--
Regards,
Patrick
Jazz Work Item Team

When you say a "background" job, I am not sure what you mean. I have tried executing my code on a spawned thread with the same result.

Your answer


Register or 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.