The simple logging/debugging tool receiving messages over UDP. The purpose is to have minimal impact on debugged application.
uzlog [options]
-h help
-p port port to listen
-a ip ip address
-o output to stdout
-c allow colored output
-f allow formatted output
-w path path to save log sessions to files. The option must be set to enable log saving.
-s path path to save data sent for saving (with msg type = 2). The option must be set to enable data saving.
Typical usage: ./uzlog -fco -p 7000
docker build -t uzlog .
docker run -it --rm -p 7000:7000/udp uzlog
The messages are sent only one way via network to endpoint. Each message belongs to specific session. The protocol is unreliable, if some packets are dropped by network, the message will be skipped.
Byte order - big endian
| message | CRC 32 |
Max packet size 508 bytes
| session (8b) | message id (4b) | message length (4b) | message offset (4b) | payload (max 488b) |
First byte determines the message type and formatting for the rest of the message:
|message type (1b) | payload |
1 - LOG
| message type = 1 (1b) | fg color (1b) | bg color (1b) | 0 (1b) | payload |
2 - SAVE
| message type = 2 (1b) | append (1b) | filename (variable size) | 0 (1b) | payload |