Library
Module
Module type
Parameter
Class
Class type
Module for parsing RFC 3164 Syslog messages
type facility =
| Kernel_Message
| User_Level_Messages
| Mail_System
| System_Daemons
| Security_Authorization_Messages
| Messages_Generated_Internally_By_Syslogd
| Line_Printer_Subsystem
| Network_News_Subsystem
| UUCP_subsystem
| Clock_Daemon
| Security_Authorization_Messages_10
| Ftp_Daemon
| Ntp_Subsystem
| Log_Audit
| Log_Alert
| Clock_Daemon_15
| Local0
| Local1
| Local2
| Local3
| Local4
| Local5
| Local6
| Local7
| Invalid_Facility
The type for Facilities
val string_of_timestamp : Ptime.t -> string
string_of_timestamp
Converts a timestamp
into a string
ctx
provides additional information to the parse
function in case one of the sub-parsers fails.
timestamp
: A timestamp
hostname
: Hostname, IPv4 or IPv6 address of the sender. "-" if unknown.set_hostname
: If true, the parse
function will skip its hostname sub-parser and use the hostname from ctx
instead.set_hostname
is automatically set by the timestamp sub-parser when it fails, because at this point it is no longer possible to determine the hostname from the input string.
parse
s a string containing a Syslog message and returns an option t