@@ -18,35 +18,35 @@ class ProcessingError(Exception):
1818
1919class AsynchronousLogstashHandler (Handler ):
2020 """Python logging handler for Logstash. Sends events over TCP.
21- :param host: The host of the logstash server.
22- :param port: The port of the logstash server (default 5959).
21+ :param host: The host of the logstash server, required.
22+ :param port: The port of the logstash server, required.
23+ :param database_path: The path to the file containing queued events, required.
2324 :param transport: Callable or path to a compatible transport class.
2425 :param ssl_enable: Should SSL be enabled for the connection? Default is False.
2526 :param ssl_verify: Should the server's SSL certificate be verified?
2627 :param keyfile: The path to client side SSL key file (default is None).
2728 :param certfile: The path to client side SSL certificate file (default is None).
2829 :param ca_certs: The path to the file containing recognized CA certificates.
29- :param database_path: The path to the file containing queued events.
3030 :param enable Flag to enable log processing (default is True, disabling
3131 might be handy for local testing, etc.)
3232 """
3333
3434 _worker_thread = None
3535
3636 # ----------------------------------------------------------------------
37- def __init__ (self , host , port = 5959 , transport = 'logstash_async.transport.TcpTransport' ,
37+ def __init__ (self , host , port , database_path , transport = 'logstash_async.transport.TcpTransport' ,
3838 ssl_enable = False , ssl_verify = True , keyfile = None , certfile = None , ca_certs = None ,
39- database_path = ':memory:' , enable = True ):
39+ enable = True ):
4040 super (AsynchronousLogstashHandler , self ).__init__ ()
4141 self ._host = host
4242 self ._port = port
43+ self ._database_path = database_path
4344 self ._transport_path = transport
4445 self ._ssl_enable = ssl_enable
4546 self ._ssl_verify = ssl_verify
4647 self ._keyfile = keyfile
4748 self ._certfile = certfile
4849 self ._ca_certs = ca_certs
49- self ._database_path = database_path
5050 self ._enable = enable
5151 self ._transport = None
5252 self ._setup_transport ()
0 commit comments