Proactor pattern
Encyclopedia
Proactor is a software design pattern
for Event handling in which long running activities are running in an asynchronous part. A Completion Handler is called after the asynchronous part has terminated.
The proactor pattern can be considered to be an asynchronous variant of the synchronous
reactor pattern
.
Standardized actors
Design pattern (computer science)
In software engineering, a design pattern is a general reusable solution to a commonly occurring problem within a given context in software design. A design pattern is not a finished design that can be transformed directly into code. It is a description or template for how to solve a problem that...
for Event handling in which long running activities are running in an asynchronous part. A Completion Handler is called after the asynchronous part has terminated.
The proactor pattern can be considered to be an asynchronous variant of the synchronous
Synchronization (computer science)
In computer science, synchronization refers to one of two distinct but related concepts: synchronization of processes, and synchronization of data. Process synchronization refers to the idea that multiple processes are to join up or handshake at a certain point, so as to reach an agreement or...
reactor pattern
Reactor pattern
The reactor design pattern is an event handling pattern for handling service requests delivered concurrently to a service handler by one or more inputs...
.
Interaction
Operation specific actors:- The Proactive Initiator starts the asynchronous operation via the Asynchronous Operation Processor and defines the Completion Handler
- Completion Handler is a call at the end of the operation from the Asynchronous Operation Processor
- Asynchronous Operation
Standardized actors
- The Asynchronous Operation Processor controls the whole asynchronous operation
- The Completion Dispatcher handles the call , depending on the execution environment.
Implementations
- Proactor and Boost.Asio (C++C++C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. It is regarded as an intermediate-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup starting in 1979 at Bell...
) - The ADAPTIVE Communication Environment (C++C++C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. It is regarded as an intermediate-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup starting in 1979 at Bell...
)
See also
- Reactor patternReactor patternThe reactor design pattern is an event handling pattern for handling service requests delivered concurrently to a service handler by one or more inputs...
(a pattern that also asynchronously queues events, but demultiplexes and dispatches them synchronously)
External links
- Proactor -An Object Behavioral Pattern for Demultiplexing and Dispatching Handlers for Asynchronous Events, Irfan Pyarali, Tim Harrison, Douglas C. SchmidtDouglas C. SchmidtDouglas C. Schmidt is a computer scientist and author known for his works in the fields of object-oriented programming, distributed computing and design patterns. Currently he is working as Associate Chair of Computer Science and Engineering and Professor of Computer Science in Vanderbilt University...
, Thomas D. Jordan, 1997 (pdf 143 kB)