About custom time-triggered transactions
The application provides infrastructure that enables you to write your own time-triggered transactions. You invoke and schedule these time-triggered transactions in much the same manner as you invoke and schedule standard time-triggered transactions.
Depending upon the way time-triggered transactions determine the list of tasks to be processed (their work load), they can be classified into one of the following categories:
- Non task-based (generic) - these time-triggered transactions use custom logic to determine the work they have to perform. They may or may not use the centralized Task Queue.
- Task-based (specific) - these time-triggered transactions use the Task Queue to determine their work.
The application provides infrastructure to create both types of custom time-triggered transactions.
The ability to write non-task-based time-triggered transactions is provided using the com.yantra.ycp.japi.util.YCPBaseAgent class. This class provides a generic infrastructure irrespective of whether the Task Queue is used or not and therefore can be used to write any time-triggered transaction.
Task-based time-triggered transactions can be programmed by subclassing the com.yantra.ycp.japi.util.YCPBaseTaskAgent class.
If your transaction is Task Queue based, it is suggested that you use the infrastructure provided specifically to write task-based transactions. This infrastructure automatically determines work for your custom agent from the Task Queue, thus reducing the amount of design and development required for your transaction.
All the custom agents written to the application specification are subclassed from the com.yantra.ycp.japi.util.YCPBaseAgent class, which has two abstract functions. When you implement these functions, they provide the processing capabilities of a time-triggered transaction.