logging.handlers.DatagramHandler

class logging.handlers.DatagramHandler(host, port)

Returns a new instance of the DatagramHandler class intended to communicate with a remote machine whose address is given by host and port.

Changed in version 3.4: If port is specified as None, a Unix domain socket is created using the value in host - otherwise, a TCP socket is created.

emit()

Pickles the record’s attribute dictionary and writes it to the socket in binary format. If there is an error with the socket, silently drops the packet. To unpickle the record at the receiving end into a LogRecord, use the makeLogRecord() function.

makeSocket()

The factory method of SocketHandler is here overridden to create a UDP socket (socket.SOCK_DGRAM).

send(s)

Send a pickled string to a socket.

doc_python
2016-10-07 17:36:09
Comments
Leave a Comment

Please login to continue.