For an application to achieve guaranteed processing, every system component must handle the logic and communication with its neighbor components that ensure guaranteed delivery.
When implementing a guaranteed processing application, you must address every component of the application, not just the Sybase CEP Engine components. The following diagram illustrates the components of an end-to-end application incorporating Sybase CEP Engine:
Messages travel through the application as follows:
From the external data source to an input adapter. The adapter may poll the external source or register for notifications or use some other mechanism to receive data.
The input adapter publishes messages to one or more data streams.
The stream(s) feed projects and query module(s).
The query module(s) publish to one or more streams.
The stream(s) feed an output adapter.
The output adapter subscribes to the stream(s), processes the messages, converts the data to a format suitable for the final destination, and then transmits the data.
The destination receives the data and performs whatever actions it is designed to do.
If just one of the components uses some other methodology, then the system as a whole will not perform guaranteed processing. For example, if the data source provides events on a best-effort basis, the entire system can only be categorized as best-effort. Similarly, if the output adapter uses at-least-once processing (messages are never dropped but may be duplicated), then the application as a whole must be considered an at-least-once processor.