Skip to content

Adds Logstash Transport to Winston@3.x with multiple input capabilities like TCP, UDP, WebSocket and HTTP

Notifications You must be signed in to change notification settings

chitkosarvesh/winston-logstash

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Modules

HTTPInput
TCPInput
UDPInput
WebSocketInput
LogstashTransport

HTTPInput

~module.exports ⏏

Kind: inner class of HTTPInput

new module.exports(options)

Param Type Description
options Object The options object returned from the LogstashTransport class

module.exports~HTTPInput

Kind: inner class of module.exports

new HTTPInput()

The class that does transmission of logs using the HTTP Requests

TCPInput

~module.exports ⏏

Kind: inner class of TCPInput

new module.exports(options)

Param Type Description
options Object The options object returned from the LogstashTransport class

module.exports~TCPInput

Kind: inner class of module.exports

new TCPInput()

The class that does transmission of logs using the TCP input

Example

node examples/basic-tcp.js

UDPInput

~module.exports ⏏

Kind: inner class of UDPInput

new module.exports(options)

Param Type Description
options Object The options object returned from the LogstashTransport class

module.exports~UDPInput

Kind: inner class of module.exports

new UDPInput()

The class that does transmission of logs using the UDP input

Example

node examples/basic-udp.js

WebSocketInput

WebSocketInput~WebSocketInput

Kind: inner class of WebSocketInput

new WebSocketInput()

The class that does transmission of logs using the WebSockets

LogstashTransport

Author: Sarvesh Chitko (chitkosarvesh@gmail.com)

module.exports ⏏

Kind: Exported class

new module.exports(options)

Param Type Description
options Object The Configuration object
options.name String The name of the transport
options.input String The input that you want to use
options.host String The Logstash server host
options.port String The port of the Logstash pipeline you've configured

module.exports~LogstashTransport ⇐ Transport

Kind: inner class of module.exports
Extends: Transport

new LogstashTransport()

The main class that adds the Logstash capabilities to Winston

Throws:

  • UnsupportedInputError
  • InvalidParametersError

module.exports~log(info, callback)

Kind: inner method of module.exports

Param Type Description
info Object The log object that needs to be sent to Logstash
callback function Callback function to call, once processing the log message is processed

About

Adds Logstash Transport to Winston@3.x with multiple input capabilities like TCP, UDP, WebSocket and HTTP

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published