Queued Requests When Engine is Stopped

The information in this article applies to product: e-Work 5.x through 6.5

Discussion

  • When the e-Work engine is started, there are a number of asynchronous components within the engine that work in their own threads independently of user intervention. Examples are the event manager (which handles flags, timers, conditionals) and the alert generator (which is responsible for keeping the eAlert table up to date).

    Requests are passed to each of these components by means of an in-memory queue. When the engine is told to shut down, these queues may still have many outstanding requests awaiting processing. Yet it’s important that the engine shuts down in a timely fashion (if the server itself is being shut down, there may be as little as 15 seconds before the process is forcibly removed from memory).

    These outstanding requests are saved to an archive file by the event manager and the alert generator. When the engine is next started, each of these components looks to see whether its archive file is present. If so it re-populates its queue with these requests. The names of the 2 files are eEventManagerArchive.DAT and eAlertCriteriaArchive.DAT. Once the files have been processed, they are deleted.

Tagged: