Skip to main content

Statistics

The "stats" node-type receives statistics of a node or path.

Prerequisites

This node-type does not have any special library dependencies. It is always available.

Implementation

The source code of the node-type is available here: https://github.com/VILLASframework/node/blob/master/lib/nodes/stats.cpp

Configuration

rate
number

A rate in Hz at which the statistics are generated by this node.

object (Input configuration (received by VILLASnode))
vectorize
integer
Default: 1

This setting allows to send multiple samples in a single message to the destination nodes.

The value of this setting determines how many samples will be combined into one packet.

Array of Hook Object (object) or Hook Name (string) (hook_list)
builtin
boolean (Builtin hook functions)
Default: true

By default, each node and paths has a couple of default hooks attached to them. With this setting the attachment of built-in hooks can be disabled.

object (Output configuration (sent out by VILLASnode))
{
  • "rate": 0,
  • "in": {
    },
  • "vectorize": 1,
  • "hooks": [
    ],
  • "builtin": true,
  • "out": {
    }
}

Example

node/etc/examples/nodes/stats.conf
nodes = {
udp_node = {
type = "socket"

in = {
address = "*:12000"
}
out = {
address = "127.0.0.1:12000"
}
}
stats_node = {
type = "stats"

node = "udp_node"
rate = 2

in = {
signals = (
{ name = "one_way_delay_mean", type = "float", stats = "udp_node.owd.mean" },
{ name = "one_way_delay_min", type = "float", stats = "udp_node.owd.lowest" },
{ name = "one_way_delay_max", type = "float", stats = "udp_node.owd.highest" }
)
}
}
}