|
| 1 | +/** |
| 2 | +* logFaces appender sends JSON formatted log events to logFaces receivers. |
| 3 | +* There are two types of receivers supported - raw UDP sockets (for server side apps), |
| 4 | +* and HTTP (for client side apps). Depending on the usage, this appender |
| 5 | +* requires either of the two: |
| 6 | +* |
| 7 | +* For UDP require 'dgram', see 'https://nodejs.org/api/dgram.html' |
| 8 | +* For HTTP require 'axios', see 'https://www.npmjs.com/package/axios' |
| 9 | +* |
| 10 | +* Make sure your project have relevant dependancy installed before using this appender. |
| 11 | +*/ |
| 12 | + |
1 | 13 | "use strict";
|
2 | 14 | var util = require('util');
|
3 | 15 | var context = {};
|
@@ -41,21 +53,19 @@ function servlet(config){
|
41 | 53 | }
|
42 | 54 |
|
43 | 55 | /**
|
44 |
| -* logFaces appender sends JSON formatted log events to logFaces receivers. |
45 |
| -* There are two types of receivers targetted - raw UDP sockets and HTTP. |
46 | 56 | * For UDP (node.js) use the following c
9EC1
onfiguration params:
|
47 | 57 | * {
|
48 |
| -* "type": "logFacesAppender", |
| 58 | +* "type": "logFacesAppender", // must be present for instantiation |
49 | 59 | * "application": "LFS-TEST", // name of the application (domain)
|
50 | 60 | * "remoteHost": "127.0.0.1", // logFaces server address (hostname)
|
51 | 61 | * "port": 55201 // UDP receiver listening port
|
52 | 62 | * }
|
53 | 63 | *
|
54 | 64 | * For HTTP (browsers or node.js) use the following configuration params:
|
55 | 65 | * {
|
56 |
| -* "type": "logFacesAppender", |
57 |
| -* "application": "LFS-TEST", // name of the application (domain) |
58 |
| -* "url": "http://lfs-server/..", // logFaces receiver binding name |
| 66 | +* "type": "logFacesAppender", // must be present for instantiation |
| 67 | +* "application": "LFS-TEST", // name of the application (domain) |
| 68 | +* "url": "http://lfs-server/logs", // logFaces receiver servlet URL |
59 | 69 | * }
|
60 | 70 | */
|
61 | 71 | function logFacesAppender(config) {
|
|
0 commit comments