Skip to Content
0

workflow deadline and program exit

Nov 01, 2016 at 10:37 PM

128

avatar image

hello folks i'm quite new with workflow... still following tutorial :).

I'm trying to use the program exit to update a table after the deadline. I have make a basic wf with a decision task. I've set the latest start. I've created the custom class and i want to trigger in the method raise_event the deadline reached to upload the tables i needed.

Here is my issue. what is the im_event value i should trigger for call the method in witch i updated the table? thank you

10 |10000 characters needed characters left characters exceeded
0
* Please Login or Register to Answer, Follow or Comment.

4 Answers

Best Answer
Mike Pokraka Nov 04, 2016 at 09:48 PM
0

Hi Marco,

Like everywhere in SAP, program exits and enhancements are usually only used if no other reasonable alternatives are available.

A modelled deadline is easier. Deadline expires, the workflow proceeds down the "Latest Start missed" branch. Add your process as a step and it's done.

There are other benefits: If you perform your action as a step in a modelled deadline then it is clear from the process what happens. People expect actions of a workflow to be along the workflow path. If something is in a program exit, it is hidden away and makes troubleshooting difficult. It makes further modification more difficult.

There are some exceptions... for example if I have a very technical function with no business relevance (e.g. replicating some info), and it is implemented for several steps, then it makes no sense to clutter up the log so I would implement that as an exit.

Regards, Mike

Share
10 |10000 characters needed characters left characters exceeded
Mike Pokraka Nov 02, 2016 at 07:17 PM
0

Why program exit? Use a modelled deadline and put a step into your latest start outcome branch that does the updating. Easier and more transparent.

Show 2 Share
10 |10000 characters needed characters left characters exceeded

Thanx for the reply. I noticed that i told lastest start instead of lastest end but i guess this don't change your comment. Please why the modelled dead line is better than the program exit. When is it better to use a program exit? thanx again.

0

Hi,

To reiterate Mike, you only use program exits and the like if there's no other way.

And to add to that, if you model it, then it shows in the log plus you can use SAP standard tools like SWI5 to get extra information and use that to increase your process.

Kind regards, Rob Dielemans

0
Marco Sposa Nov 03, 2016 at 08:31 AM
0

Hello, thank you for the reply, that was the tutorial that i was following, i succeded in creating my exit. The trouble is succeding in understand witch even is trigger when the deadline is reatched. I though it was

swfco_event_after_rule_exec but it wasn't if i use swfco_event_state_changed the exit triggered too many times.

I only want to understand if i need check an event, an workitem attribute or something else to make my exit run at the deadline.

Regards

Share
10 |10000 characters needed characters left characters exceeded
Florin Wach Nov 15, 2016 at 12:50 PM
0

Hello everyone,

trying to use Workflow-Exits during the Deadling-Escalation is a DEAD END, as the status of the original workitem is not changed. So there is no workitem-exit called during the missing of a deadline. I tried to figure that out for a couple of days and debugged through the RSWWDHEX and finally gave up on it, as the very only chance to enable coding there, was a BIG modification in that program.

You have to go through the modeled deadline scenario, as Mike has already suggested.

Florin

Share
10 |10000 characters needed characters left characters exceeded