12 #ifndef ROC_NODE_RECEIVER_H_
13 #define ROC_NODE_RECEIVER_H_
72 size_t* sess_metrics_size,
73 void* sess_metrics_arg);
100 : core::RefCounted<Slot, core::PoolAllocation>(pool)
115 return index1 == index2;
120 void update_compatibility_(
address::Interface iface,
const address::EndpointUri& uri);
122 core::SharedPtr<Slot> get_slot_(
slot_index_t slot_index,
bool auto_create);
123 void cleanup_slot_(Slot& slot);
124 void break_slot_(Slot& slot);
126 virtual void schedule_task_processing(pipeline::PipelineLoop&,
128 virtual void cancel_task_processing(pipeline::PipelineLoop&);
132 pipeline::ReceiverLoop pipeline_;
133 ctl::ControlLoop::Tasks::PipelineProcessing processing_task_;
135 core::SlabPool<Slot> slot_pool_;
136 core::Hashmap<Slot> slot_map_;
141 core::Array<pipeline::ReceiverSessionMetrics, 8> sess_metrics_;
Base class for hashmap element.
Base class for object with reference counter.
struct PortHandle * PortHandle
Opaque port handle.
Context & context()
All nodes hold reference to context.
bool has_broken()
Check if there are broken slots.
bool get_metrics(slot_index_t slot_index, pipeline::ReceiverSlotMetrics &slot_metrics, sess_metrics_func_t sess_metrics_func, size_t *sess_metrics_size, void *sess_metrics_arg)
Get slot metrics.
bool unlink(slot_index_t slot_index)
Remove slot.
uint64_t slot_index_t
Slot index.
bool configure(slot_index_t slot_index, address::Interface iface, const netio::UdpReceiverConfig &config)
Set interface config.
bool bind(slot_index_t slot_index, address::Interface iface, address::EndpointUri &uri)
Bind to local endpoint.
void(* sess_metrics_func_t)(const pipeline::ReceiverSessionMetrics &sess_metrics, size_t sess_index, void *sess_arg)
Callback for getting session metrics.
bool is_valid()
Check if successfully constructed.
sndio::ISource & source()
Get receiver source.
Receiver(Context &context, const pipeline::ReceiverConfig &pipeline_config)
Initialize.
Pipeline task scheduler interface. PipelineLoop uses this interface to schedule asynchronous work....
struct SlotHandle * SlotHandle
Opaque slot handle.
struct SlotHandle * SlotHandle
Opaque slot handle.
Pipeline task scheduler interface.
@ Iface_Max
Number of interfaces.
hashsum_t hashsum_int(int16_t)
Compute hash of 16-bit integer.
int64_t nanoseconds_t
Nanoseconds.
size_t hashsum_t
Hash type.
Base class for object with reference counter.
Commonly used types and functions.
Metrics of receiver session (connection from sender).
Metrics of receiver slot.