Executing Issue Computations

Issue computations are always executed as part of a workflow. There are two different styles of workflow. In the MPT, workflows are Java classes and manipulated as "pure code". Within the SPT, workflows are manipulated visually like a flow chart.

The following code sample shows an issue being raised programmatically in a workflow within the MPT.

@UsePersonalizedIssues
public class ZBKS_InsertOrUpdate implements Callback<Book> {
public void execute(ActionBasedWorkflowContext<Book> context) {
// merge records from input to current
workflowService.mergeInputToCurrent(context);
 
workflowService.executeIssueComps(context, context.getCurrent().getModels(), "ZBKS.NotInGoodCondition");
// write records to database
workflowService.write(context.getCurrent().getModels(), context);
}


Actions can be invoked anywhere within your application. As such you can raise issues in any class such as REST resources, IXM Engine tasks, etc.

Changes to the MPT require you to build and restart your server.