Question

8
Replies
1595
Views
MadhavaRaoJ Member since 2013 3 posts
Amerprise Financial
Posted: 5 years ago
Last activity: 5 years 4 months ago
Closed
Solved

Declare Trigger Activty

We have a declare trigger activity defined at the work object class to commit few changes to one physical data base table with pyStatuswork & one other Specific tracking properties. At the trigger activity we have the necessary property set for the new class (mapped to physical DB table) with Obj-Save adding to the deferred list and expecting the Deferred save to commit the changes with the Assignment/Work object commit.

Problem Statement: Work Object status was changing from Open* to Resolved* and since we had a Declare trigger event on status & other specific property we have two events logged one from Open Status & other from Resolved Status. Our trigger activity is firing with two Obj-Save one with Open Status timestamp of 20150618T165945.245 GMT and 20150618T165945.927 GMT of Resolve timestamp and expecting when final commit happens the Obj-Save with the deferred list should execute in the order of queue (First come first out) execution. But in our case the Resolved one is executing first.

Attempted Solution: We tried using explicit Commit since Trigger activity doesn't allow Obj-Save with write now and it worked correctly. As this method forcing work object changes to commit and no deferred list.

As per Pega Help documentation Commit/Obj-Save with write now shouldn't be used with Declare triggers.

Please share your inputs if you have come across such issues.

***Updated by moderator: Lochan to close post***
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.

Case Management
Moderation Team has archived post
Share this page LinkedIn