This article is about a multi-threading technique. For the lockstep protocol variant, see Active objects.
The Active Object design pattern decouples method execution from method invocation that reside in their own thread of control.s The goal is to introduce concurrency, by using asynchronous method invocation and a scheduler for handling requests.
The pattern consists of six elements:
* a proxy, which provides an interface towards clients with publicly accessible methods
* an interface which defines the method request on an active object
* a list of pending requests from clients
* a scheduler, which decides which request to execute next
* the implementation of the active object method.
* a callback or variable for the client to receive the result.
The Active Object design pattern decouples method execution from method invocation that reside in their own thread of control.s The goal is to introduce concurrency, by using asynchronous method invocation and a scheduler for handling requests.
The pattern consists of six elements:
* a proxy, which provides an interface towards clients with publicly accessible methods
* an interface which defines the method request on an active object
* a list of pending requests from clients
* a scheduler, which decides which request to execute next
* the implementation of the active object method.
* a callback or variable for the client to receive the result.
No comments:
Post a Comment