Status of group workflow task created using SOAP web services createWorkFlowTask is Wait not Pending
search cancel

Status of group workflow task created using SOAP web services createWorkFlowTask is Wait not Pending

book

Article ID: 133321

calendar_today

Updated On:

Products

CA Service Management - Service Desk Manager CA Service Desk Manager

Issue/Introduction

I'm creating workflow tasks via web services. There is an existing block of tasks within a Group Start task and a Group End block.  The existing tasks in the block are all in "Pending" status.

I receive different results, depending on the method used to create a new workflow task within the group:

  1. If I create a workflow task for a ticket manually, via the web browser interface, it gets created with "Pending" status.
  2. If I create a workflow task via the createWorkFlowTask web services API, it gets created with "Wait" status.

I need the new group tasks to be created with "Pending" status, so that the approvers can validate them without waiting for the previous tasks to be approved.

Environment

Release : 17.1, 17.2

Component : SERVICE DESK MANAGER

Cause

When working with group workflow tasks, specifying a sequence number for the new task is not sufficient if the group task has already been started (i.e. the status of the Group Start task is "Complete").

Resolution

Set the value of "selectedWorkFlow" in the call to createWorkFlowTask. For example, set the value to "PREVIOUS_TASK_".


Additional Information

Depending on how much activity is taking place, read:  number of workflows being created/ updated, one may also be experiencing an issue with "Unable to obtain DomSession XXX" error appearing in the stdlogs.

One may consider inserting a code delay prior to logout of the given web service session of about 10 seconds to allow for the session domsrvr objects time to recover and complete activity.  Additionally, one may consider introducing NX_SESSION_OBJECT_DELETE_DELAY value set to 270 in the NX.env

Here is some sample XML that has been used with the SoapUI tool:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://www.ca.com/UnicenterServicePlus/ServiceDesk">
   <soapenv:Header/> 
   <soapenv:Body> 
      <ser:createWorkFlowTask> 
         <sid>1468054208</sid> 
         <attrVals> 
            <string>sequence</string> 
            <string>40</string> 
         </attrVals> 
         <objectHandle>cr:400507</objectHandle> 
         <creatorHandle>cnt:378D4881DA6F0F4FA49C78BE2AC19786</creatorHandle> 
         <selectedWorkFlow>PREVIOUS_TASK_</selectedWorkFlow> 
         <taskType>APP</taskType> 
         <attributes> 
         </attributes> 
         <createWorkFlowTaskResult></createWorkFlowTaskResult> 
         <newHandle></newHandle> 
      </ser:createWorkFlowTask> 
   </soapenv:Body> 
</soapenv:Envelope>