# remotelogger

> This server is able to receive logs from javascript remote application

Latest version **2.0.2** (published 2015-07-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install remotelogger
pnpm add remotelogger
yarn add remotelogger
bun add remotelogger
```

Provides the command `remotelogger`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.2 |
| Published | 2015-07-10 |
| First published | 2014-10-31 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 (+2 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Olivier DAUMAS |
| Maintainers | krysalead |
| Keywords | HTTP, log, Remote, Mobile |

## Links

- npm: https://www.npmjs.com/package/remotelogger
- Repository: https://github.com/krysalead/Remotelogger
- Issues: https://github.com/krysalead/Remotelogger/issues
- npm.io page: https://npm.io/package/remotelogger

## Dependencies (2)

- [yargs](https://npm.io/package/yargs.md) 1.3.2
- [request](https://npm.io/package/request.md) 2.53.0

## Alternatives

- [cli-color](https://npm.io/package/cli-color.md) — 3.4M weekly downloads
- [log](https://npm.io/package/log.md) — 1.3M weekly downloads
- [logstash-client](https://npm.io/package/logstash-client.md) — 4.5K weekly downloads
- [@nocobase/plugin-logger](https://npm.io/package/@nocobase/plugin-logger.md) — 2.0K weekly downloads
- [child-process-debug](https://npm.io/package/child-process-debug.md) — 695 weekly downloads

## Recent versions

- 2.0.2 (latest) — 2015-07-10
- 2.0.1 — 2015-07-10
- 2.0.0 — 2015-04-02
- 1.0.8 — 2015-03-18
- 1.0.6 — 2014-11-06
- 1.0.5 — 2014-11-06
- 1.0.4 — 2014-11-05
- 1.0.3 — 2014-11-05
- 1.0.1 — 2014-11-05
- 1.0.0 — 2014-10-31

## README

Remotelogger
===========

Remote Logger is a node module able to handle request with strings and to put in a log file and the console.
The JavaScript sample client code is based on [Aria-Templates](http://ariatemplates.com/) scripts and a standard JavaScript one.

* Run the server
* Load in your code the javascript
* Call the logger method
 
How to use it
=============

Installation
------------------
```bash
npm install -g remotelogger
```

Run it
------------------

```bash
remotelogger
```

Message Structure
------------------

Here is the URL to do a remote log : 
```bash
curl http://localhost:8666/log/?classname=com.mycompany.test&log=This is my log message message&sev=DEBUG&logdate=1426844546265&depth=4&senddate=1426844546265
```

```json
{
	cl : "ClassName or identifier of the javascript that did the log",
	log : "Log Message",
	logdate : "Date of the log (as we are queuing the message to ensure the order of reception)",
	depth : "Depth of the call stack not used ",
	senddate:"Date when the log was send from the client (Must be UTC time so we can calculate the request time)",
	sev : "The severity of the log [DEBUG,INFO,ERROR,WARN]"
}
```

Web
-------------------

open [http://localhost:8666/www/](http://localhost:8666/www/) you will land on an interface allowing to see the log in web mode (search tool from the browser) and also see the occurency of call of a class (identifier). If you add a "Entering" keyword in your log in each of first line of your function, it will be able to draw a sequence diagram.


Options
------------------
* Filtering on the logs, this allow to display on the file and the console only what is matching the filter

```bash
remotelogger --filter mainpage
```
Only logs containing **mainpage** will be displayed

* Log file, by default the log is done on the console, if you want to store in a file.

```bash
remotelogger --logfile myfile.log
```

The web part of the remote logger can use [firebase](http://firebase.com/) for live update.

```bash
remotelogger --firebase https://YOURURL.firebaseio.com
```

Known Issues
--------------

On OSX we have to link node installation as it is in linux system.

Web application is slow on huge amount of data TODO : improve it.

```bash
sudo ln -s /usr/local/bin/node /usr/bin/node
```

---
_Source: https://npm.io/package/remotelogger · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
