xrootdlib.streams.XrdXrootdMon package¶
Stream of the XrdXrootdMon monitoring messages
This module presents a high-level stream representation of the XrdXrootdMon
struct
primitives.
It provides two stream mechanisms of different complexity:
stream_packets
provides an ordered stream of rawPacket
map_streams
provides a stream offstat
,redir
,trace
, andmap
-
class
stream_packets
(*slave_args, **slave_kwargs)¶ Bases:
chainlet.genlink.GeneratorLink
Provide a stream of packets from a readable bytes buffer
Parameters: - packet_source – a bytes buffer providing serialised packet data
- sort_window – window size in which to sort packets by their assigned order
The
packet_source
may be any bytes buffer supportingread
operations. This can be an open file, but also a socket or wrapped memory. While the buffer may be extended indefinitely, it should always contain complete packets.The
sort_window
is required to ensure ordering of the packet data. Since XRootD uses several packet buffers, concurrent packets may arrive in arbitrary order. To remove this ambiguity,sort_window
packets are buffered and provided in order.Note that an ideal
sort_window
corresponds to the number of out-of-order packets. It is not to the maximum difference in ordering of each packet.
-
map_streams
¶ alias of
xrootdlib.streams.XrdXrootdMon.StreamMapper