|
VLink 2.0.0
A high-performance communication middleware
|
Request/acknowledgement synchronisation manager for blocking RPC calls. More...
#include <functional>#include <memory>#include <mutex>#include <set>#include "../base/condition_variable.h"#include "../base/macros.h"Go to the source code of this file.
Classes | |
| class | vlink::AckManager |
| Thread-safe request/acknowledgement synchronisation manager. More... | |
| struct | vlink::AckManager::Request::Compare |
Namespaces | |
| namespace | vlink |
Request/acknowledgement synchronisation manager for blocking RPC calls.
AckManager provides the blocking/notify mechanism used by the VLink method model (Client / Server) to implement synchronous request/response round-trips across transports. A caller creates a Request token, invokes process() to send the request and wait for its acknowledgement, and either the transport callback calls notify() on the same request or the caller can cancel it via remove().
clear() marks the manager as interrupted and wakes all waiting process() callers, causing them to return false. This is used during shutdown to unblock any in-flight RPC calls.process() may be called from multiple threads simultaneously; each call tracks its own RequestPtr.