8 #ifndef DRIPLINE_SERVICE_HH_ 9 #define DRIPLINE_SERVICE_HH_ 78 public std::enable_shared_from_this< service >
85 exchange_declared = 20,
94 service(
const scarab::param_node& a_config = scarab::param_node(),
const std::string& a_queue_name =
"",
const std::string& a_broker_address =
"",
unsigned a_port = 0,
const std::string& a_auth_file =
"",
const bool a_make_connection =
true );
95 service(
const bool a_make_connection,
const scarab::param_node& a_config = scarab::param_node() );
104 mv_accessible(
bool, enable_scheduling );
137 virtual bool open_channels();
139 virtual bool setup_queues();
141 virtual bool bind_keys();
143 virtual bool start_consuming();
145 virtual bool stop_consuming();
147 virtual bool remove_queue();
151 virtual bool listen_on_queue();
157 virtual void send_reply(
reply_ptr_t a_reply )
const;
159 mv_accessible(
uuid_t,
id );
163 mv_referrable( sync_map_t, sync_children );
166 mv_referrable( async_map_t, async_children );
168 mv_referrable( std::string, broadcast_key );
174 virtual void do_cancellation(
int a_code );
179 a_request->sender_service_name() = f_name;
185 a_reply->sender_service_name() = f_name ;
191 a_alert->sender_service_name() = f_name;
virtual sent_msg_pkg_ptr send(request_ptr_t a_request) const
std::shared_ptr< sent_msg_pkg > sent_msg_pkg_ptr
std::shared_ptr< msg_request > request_ptr_t
std::shared_ptr< msg_alert > alert_ptr_t
virtual sent_msg_pkg_ptr send(request_ptr_t a_request) const
Sends a request message and returns a channel on which to listen for a reply.
Consumer of Dripline messages on a particular queue.
Executes scheduled events.
Convenience class to bring together listener and concurrent_receiver.
boost::uuids::uuid uuid_t
Universally-unique-identifier type containing 16 hexadecimal characters.
std::shared_ptr< endpoint > endpoint_ptr_t
std::map< std::string, endpoint_ptr_t > sync_map_t
std::shared_ptr< msg_reply > reply_ptr_t
Basic AMQP interactions, including sending messages and interacting with AMQP channels.
std::map< std::string, lr_ptr_t > async_map_t
std::shared_ptr< message > message_ptr_t
Basic Dripline object capable of receiving and acting on messages.
A heartbeater repeatedly sends an alert on a particular time interval.