Support Article
pyItemStatus stuck at Now-Processing state
SA-8479
Summary
For a CI work item the entry is getting created in pr_sys_queue with pyItemStatus: Scheduled that changes to Now-Processing within 30 seconds in line with agent interval.
pxobjclass: System-Queue-DemoProcessing
pyAgentName: WorkMgmtFW:ProcessDemoRequests
pyItemStatus: Now-Processing
Agents ruleset WorkMgmtFW has agent ProcessDemoRequests with Activity ProcessDemoRequests and Class ABC-.
You are unable to trace the agent from SMA that suggests that the agent is not picking the work item and the activity is not getting executed.
Agent queue item continues to be at the status of Now-Processing.
Error Messages
Not Applicable
Steps to Reproduce
Create agent ProcessDemoRequests and Activity ProcessDemoRequests of Class ABC- to process a work item of class System-Queue-DemoProcessing.
Root Cause
Queue class must be inherited from System-Queue- to be processed by a standard agent. If there is no relation between Queue class and the class given on agent rule form, then the Engine maps the given class with SYSTEM-QUEUE-DEFAULTENTRY. Since the Stored Procedure that was used to lock (mark ‘now-processing’) does not consider the class relation, it succeeds in locking. When the agent processes the entry, it tries to get the entry where class equals to SYSTEM-QUEUE or SYSTEM-QUEUE-DEFAULTENTRY and this fails.
Resolution
Changing the class from ABC- to System-Queue-DemoProcessing (from application specific class to the queued class, that is, inheriting from System-Queue) for both the Agent and the Activity resolves the issue.
Published June 12, 2015 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.