1. Open the Batch
job form. Click System administration > Inquiries > Batch
jobs > Batch jobs.
2. Create a new batch job.
3. Set up the following batch job and click the View tasks button.
4. The Company accounts and Class name fields are mandatory. The Task description, Has conditions and Batch group fields are optional but recommended.
5. Add four tasks that use the following classes to the batch job: AifGatewayReceiveService, AifGatewaySendService, AifInboundProcessingService, andAifOutboundProcessingService.
6. Set a recurrence interval for the batch job. For testing purposes, it is convenient to set the interval to one minute.
7. To start the batch job, change its status to Waiting
2. Create a new batch job.
3. Set up the following batch job and click the View tasks button.
4. The Company accounts and Class name fields are mandatory. The Task description, Has conditions and Batch group fields are optional but recommended.
5. Add four tasks that use the following classes to the batch job: AifGatewayReceiveService, AifGatewaySendService, AifInboundProcessingService, andAifOutboundProcessingService.
6. Set a recurrence interval for the batch job. For testing purposes, it is convenient to set the interval to one minute.
7. To start the batch job, change its status to Waiting
Run
AIF inbound and outbound manually
Here are two jobs to run
inbound and outbound messages manually, so you don’t have to wait for the
batches to pick them up.
Inbound:
static void KlForrunAIFInbound(Args _args)
{
;
// read the messages
new AifGateWayReceiveService().run();
// process the messages in queue
new AifInboundProcessingService().run();
info("done");
}
{
;
// read the messages
new AifGateWayReceiveService().run();
// process the messages in queue
new AifInboundProcessingService().run();
info("done");
}
Outbound:
static void KlForrunAIFOutbound(Args _args)
{
;
// process messages in queue
new AifOutboundProcessingService().run();
// send messages
new AifGateWaySendService().run();
info("done");
}
{
;
// process messages in queue
new AifOutboundProcessingService().run();
// send messages
new AifGateWaySendService().run();
info("done");
}
Ofcourse, you can put
this code in classes, or combine them so they are executed together. Because
inbound messages can trigger outbound messages, it’s better to process the
inbound messages before the outbound messages.
.
No comments:
Post a Comment