Event logging with distributed database for node.j

2019-04-14 01:48发布

I am looking for system or library for node.js, that can log information about client access on every remote server and automatically gather that information on central log server for later analysis. Remote server will have write only access, while central server will accumulate a lot of data to read.

I hope there is solution using distributed [NoSQL] database, like MongoDB. However I have not found how to set it up.

For example I hope that cleaning old data can be initiated on central log server (when data has been processed) and entries on old dates can be removed on remote server with little overhead.

Currently we have logging into files and Hadoop system for log analysis. But I think we need to accumulate data in database.

3条回答
做自己的国王
2楼-- · 2019-04-14 02:07

MongoDB or any other distributed databases will not solve problem. In-house project must be created. Some features of MongoDB for consideration:

Capped Collections are actually way to loose data. I may be good for short history.

查看更多
戒情不戒烟
3楼-- · 2019-04-14 02:15

Winston, currently the best logging framework for node.js, has option to log into MongoDB or CouchDB.

查看更多
爷的心禁止访问
4楼-- · 2019-04-14 02:18

Scribe could be what you're looking for. There are node packages too

I have never checked it out so I'd be interested in reading your thoughts in the comments if you investigate it and find it good/bad, easy/hard to setup, etc.

查看更多
登录 后发表回答