Setting a Custom Task or Process to run on an Epicor Schedule

Setting a Custom Task or Process to run on an Epicor Schedule

Once you start automating, sooner or later you want something to happen at a particular time, not just because something else happened.

If you’re using Epicor, you have the System Agent to do that for built-in process and tasks, and you can set reports to happen at certain times.

What if it’s something completely custom?

Or maybe it should happen when triggered, but after a delay?

Ah …

There has been a module specially for that, but you don’t need it.

(You can also use Service Connect, if you have that, but if you do, you probably know that).

Epicor is very good about allowing even the deeper guts of the system to be used in BPMs, so that means you can automate the scheduling too.

When something needs to happen, but not quite yet, you can create or alter a schedule instead of doing the task directly. A second BPM set can then fire when the schedule changes to do the actual work.

Obviously these schedule-related BPMs need constructing with great care, because they will fire for every schedule change of every kind. They need conditions which exit as soon as possible when they are not required.

There are a few ways this can be useful.

We use this for some tricky integration components, for example, where data needs to be synced to an external system. In some cases we need to be sure that Epicor has finished complex updates before the sync happens, so it’s wise to delay, or the sync process would interrupt further triggers that need to complete so the user can finish their task. In others, a constant mass of data would swamp the integration system, so updates are added to a queue until the last is complete and then all sent at once.

That last case is particularly interesting, because it provides a neat way to handle things that happen in batches (invoice posting, for example). Each event moves the schedule on a little further, so the final scheduled task automatically happens only when there’s a break for it.

Warning

As I’ve already hinted above, DO NOT APPLY THIS TECHNIQUE RASHLY.

If you don’t know what you’re doing, particularly with data directives, leave this method well alone, because you could gum up your Epicor system and slow it to a crawl. But it’s very powerful and solves otherwise insoluble problems, done with care and precision.