Skip to content
pewsou edited this page May 7, 2022 · 4 revisions

ASFK - Asynchronous Flow Kit.

This is an attempt to introduce some framework to simplify building of SW with asynchronous flow. The intent is is to provide a set of asynchronous patterns, which will provide simple and consistent API for data processing, thus saving the effort for programer.

Architecture

The Kit is built as a collection of independent objects each of which represents some concurrency pattern. The API provides consistent set of operations while the set is split to 2 groups: one for concurrent/asynchronous execution, other for conditioned execution (will be available in future).

Semantics

In the course of this SW package next terms defined:

  1. Procedure - this is routine provided by caller ("block" in terms of Obj-C) that only supposed to process data fed by set of arguments.
  2. Summary - a routine provided by caller that is called when data processing session is done. It receives execution results as parameter.
  3. Method "callXXX" - blocking method; it will always return only AFTER all the procedures that have started by this call also have ended and summary was called (if exists).
  4. Method "castXXX" - non-blocking method; it will always return without waiting for ending of procedures.
  5. Method "storeXXX/addXXX" - adds the items (usually procedures) to the instance of the object so any future invocation of cast/call will involve the new definitions.
  6. Method "replaceXXX" - replaces the stored items in the instance of the object with new collection (probably empty one) so any future invocation of cast/call will involve the new definitions.
  7. Session - any batch of data submitted to processing by single call of call/cast method OR set of procedures submitted for repeated execution. Each session has unique ID.
Clone this wiki locally