log.io
Listens for new messages over TCP and broadcasts to browsers via socket.io
Last updated 14 days ago by msmathers .
Apache-2.0 · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install log.io 
SYNC missed versions from official npm registry.

Log.io - Real-time log monitoring in your browser

License Version Node

Powered by node.js + socket.io

How does it work?

A file input watches log files for changes, sends new messages to the server via TCP, which broadcasts to browsers via socket.io.

Terminology

Stream - A logical designation for a group of messages that relate to one another. Examples include an application name, a topic name, or a backend service name.

Source - A physical designation for a group of messages that originate from the same source. Examples include a server name, a service provider name, or a filename.

Input - A (stream, source) pair.

While originally designed to represent backend service logs spread across multiple servers, the stream/source abstraction is intentionally open-ended to allow users to define a system topology for their specific use case.

Install & run server

Install via npm

npm install -g log.io

Configure hosts & ports (see example below)

nano ~/.log.io/server.json

Run server

log.io-server

Browse to http://localhost:6688

Install & run input

Begin sending log messages to the server via:

Server configuration

There are two servers: the message server, which receives TCP messages from message inputs, and the HTTP server, which receives requests from browsers. By default, the application looks for configuration in ~/.log.io/server.json, and can be overridden with the environment variable LOGIO_SERVER_CONFIG_PATH.

Sample configuration file:

{
  "messageServer": {
    "port": 6689,
    "host": "127.0.0.1"
  },
  "httpServer": {
    "port": 6688,
    "host": "127.0.0.1"
  },
  "debug": false,
  "basicAuth": {
    "realm": "abc123xyz",
    "users": {
      "username1": "password1"
    }
  }
}

basicAuth and debug are both optional keys that can be omitted.

Server TCP interface

The file input connects to the server via TCP, and writes properly formatted strings to the socket. Custom inputs can send messages to the server using the following commands, each of which ends with a null character:

Send a log message

+msg|streamName1|sourceName1|this is log message\0

Register a new input

+input|streamName1|sourceName1\0

Remove an existing input

-input|streamName1|sourceName1\0

Current Tags

  • 0.4.16                                ...           latest (14 days ago)

28 Versions

  • 0.4.16                                ...           14 days ago
  • 0.4.15                                ...           a month ago
  • 0.4.14                                ...           a month ago
  • 0.4.13                                ...           2 months ago
  • 0.4.12                                ...           2 months ago
  • 0.4.11                                ...           3 months ago
  • 0.4.10                                ...           3 months ago
  • 0.4.8                                ...           4 months ago
  • 0.4.7                                ...           4 months ago
  • 0.4.6                                ...           5 months ago
  • 0.4.5                                ...           5 months ago
  • 0.4.4                                ...           5 months ago
  • 0.4.3                                ...           5 months ago
  • 0.4.2                                ...           5 months ago
  • 0.4.1                                ...           5 months ago
  • 0.4.0                                ...           5 months ago
  • 0.3.4                                ...           6 years ago
  • 0.3.3                                ...           7 years ago
  • 0.3.2                                ...           7 years ago
  • 0.3.1                                ...           7 years ago
  • 0.3.0                                ...           7 years ago
  • 0.2.7                                ...           8 years ago
  • 0.2.6                                ...           8 years ago
  • 0.2.5                                ...           8 years ago
  • 0.2.4                                ...           8 years ago
  • 0.2.3                                ...           8 years ago
  • 0.2.2                                ...           8 years ago
  • 0.2.1                                ...           9 years ago
Maintainers (1)
Downloads
Today 0
This Week 9
This Month 9
Last Day 4
Last Week 15
Last Month 71
Dependencies (4)
Dependents (1)

Copyright 2014 - 2016 © taobao.org |