9#include "plugin_base.h"
10#include "../message_stringifier.h"
13#if !defined(NDEBUG) && !defined(ROTOR_DEBUG_DELIVERY)
14#define ROTOR_DO_DELIVERY_DEBUG 1
17namespace rotor::plugin {
52#if !defined(ROTOR_DO_DELIVERY_DEBUG)
63 using plugin_base_t::plugin_base_t;
85 using delivery_plugin_base_t::delivery_plugin_base_t;
90 const std::type_index &
identity() const noexcept
override {
return class_identity; }
92 inline size_t process() noexcept override;
95template <typename LocalDelivery>
intrusive_ptr_t< message_base_t > message_ptr_t
intrusive pointer for message
Definition message.h:118
std::deque< message_ptr_t > messages_queue_t
structure to hold messages (intrusive pointers)
Definition message.h:121
universal primitive of concurrent computation
Definition actor_base.h:47
Message subscription and delivery point.
Definition address.hpp:33
Abstract interface for making textual/string representation of a message.
Definition message_stringifier.h:36
base implementation for messages delivery plugin
Definition delivery.h:62
virtual size_t process() noexcept=0
main messages dispatcher interface
templated message delivery plugin, to allow local message delivery be customized
Definition delivery.h:84
static const std::type_index class_identity
Definition delivery.h:88
const std::type_index & identity() const noexcept override
returns pointer, which uniquely identifiess plugin type
Definition delivery.h:90
size_t process() noexcept override
main messages dispatcher interface
debugging local message delivery implementation with dumping details to stdout.
Definition delivery.h:42
static void discard(message_ptr_t &message, const message_stringifier_t *stringifier) noexcept
dumps discarded message
static void delivery(message_ptr_t &message, const subscription_t::joint_handlers_t &local_recipients, const message_stringifier_t *stringifier) noexcept
delivers the message to the recipients, possibly dumping it to console
basic local message delivery implementation
Definition delivery.h:23
static void delivery(message_ptr_t &message, const subscription_t::joint_handlers_t &local_recipients) noexcept
delivers an message for self of one of child-actors (non-supervisors)
base class for all actor plugins
Definition plugin_base.h:23
pair internal and external handler_t
Definition subscription.h:40
Holds and classifies message handlers on behalf of supervisor.
Definition subscription.h:30