DTOs used in cloudless resource monitoring system
Project description
Cloudless Resource Management Data Transfer Objects
List of Data Transfer Objects that:
- are encapsulated in UDP packets and transferred back and forth between workers and collector in the generation layer
- are exchanged within between modules inside either worker or collector
List of DTOs
Internal objects
-
PortInfo
: a pair of (daemon_name,port_number) showing that a daemon can receive packets at certain port, and is encapsulated inHostInfo
object.Ex: collectord:9090 => collectord service is listening at port 9090
-
HostType
: enum class, label of host used to identify which kind that host is and is encapsulated inHostInfo
object.Ex: WORKER => worker host; COLLECTOR => collector host.
-
HostInfo
: information of a single host (collector or worker) that will be sent to other host by encapsulated inProbeInit
orProbeAck
object.Ex:
COLLECTOR-collector[10.0.0.2] - ports: [coordinatord:10100, collectord:9090]
=> hostname: collector; ip_address: 10.0.0.2, 2 daemons: collectord listening at port 9090 & coordinatord listening at port 10100; host_type: COLLECTOR
-
CrmPktType
: enum class, label of packet used to identify which kind that data inside a UDP segment is and is encapsulated inProbeInit
,ProbeAck
, orRegisterAck
object/packet.Ex: PROBE_INIT => UDP packet of type ProbeInit; PROBE_ACK => UDP packet of type ProbeAck; REG_ACK => UDP packet of type RegisterAck packet.
-
RegisterInfo
: information regarding the creation of metric exporters in worker host and is encapsulated inRegisterAck
object/packet.Ex:
True - ('Successfully registered at collector host.',) - max remaining retries: 0
=> status: True; message: 'Successfully registered to collector host.'; max_retries: 0
False - ('Failed to register at collector host.',) - max remaining retries: 3
=> status: False; message: 'Failed to register to collector host.'; max_retries: 3
Application layer PDU
-
ProbeInit
: broadcasted by collector host (in fixed interval) to all worker host within current subnet.Ex:
{"py/object": "dtos.probe_init.ProbeInit", "id": "78f6ac6d-ec8d-44cf-abc8-584e4255e9d3", "info": {"py/object": "dtos.host_info.HostInfo", "hostname": "collector", "inet_addr": "10.0.0.2", "ports": [{"py/object": "dtos.port_info.PortInfo", "daemon": "coordinatord", "port": 10100}, {"py/object": "dtos.port_info.PortInfo", "daemon": "collectord", "port": 9090}], "type": {"py/reduce": [{"py/type": "dtos.host_type.HostType"}, {"py/tuple": [2]}]}}, "type": {"py/reduce": [{"py/type": "dtos.crm_pkt_type.CrmPktType"}, {"py/tuple": [1]}]}}
=> object: ProbeInit; packet-id: 78f6ac6d-ec8d-44cf-abc8-584e4255e9d3; HostInfo: hostname=collector, inet_addr=10.0.0.2
-
ProbeAck
: sent by worker host as reply toProbeInit
packet of collector hostEx:
-
RegisterAck
:
Versions:
2.1.x
: with QueryAck3.x.x
: without QueryAck
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for tl_crmdtos-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eceeb4cab286f771c4e3448024b811d389585ff735cc5ebd2b7a70aa76cd5280 |
|
MD5 | 312040423a5441e6e88c6fe40445ad55 |
|
BLAKE2b-256 | 44bab6ce6f9ff8586da8dacb2e75d0b78724481ac38a48de9a57c6eb688c2d38 |