8000
File tree Expand file tree Collapse file tree 2 files changed +17
-10
lines changed Expand file tree Collapse file tree 2 files changed +17
-10
lines changed Original file line number Diff line number Diff line change 1
- //Note that hipchat appender needs hipchat-client to work.
2
- //If you haven't got hipchat-client installed, you'll get cryptic
3
- //"cannot find module" errors when using the hipchat appender
1
+
2
+ /**
3
+ * !!! The hipchat-appender requires `hipchat-notifier` from npm
4
+ * - e.g. list as a dependency in your application's package.json
5
+ */
6
+
4
7
var log4js = require ( '../lib/log4js' ) ;
5
8
6
9
log4js . configure ( {
7
10
"appenders" : [
8
11
{
9
12
"type" : "hipchat" ,
10
- "api_key" : 'Hipchat_API_V1_Key' ,
11
- "room_id" : "Room_ID" ,
12
- "from" : "Tester" ,
13
- "format" : "text" ,
14
- "notify" : "NOTIFY" ,
15
- "category" : "hipchat"
13
+ "hipchat_token" : "< User token with Notification Privileges >" ,
14
+ "hipchat_room" : "< Room ID or Name >" ,
15
+ // optionl
16
+ "hipchat_from" : "[ additional from label ]" ,
17
+ "hipchat_notify" : "[ notify boolean to bug people ]"
16
18
}
17
19
]
18
20
} ) ;
@@ -25,4 +27,4 @@ logger.trace("Test Trace Message");//so debug and trace are the same color: purp
25
27
logger . fatal ( "Test Fatal Message" ) ; //hipchat client has limited color scheme
26
28
logger . error ( "Test Error Message" ) ; // fatal and error are same color: red
27
29
logger . all ( "Test All message" ) ; //grey
28
- //logger.debug("Test log message");
30
+ //logger.debug("Test log message");
Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ exports.configure = hipchatConfigure;
8
8
9
9
/**
10
10
@invoke as
11
+
11
12
log4js.configure({
12
13
"appenders": [
13
14
{
@@ -21,6 +22,10 @@ exports.configure = hipchatConfigure;
21
22
}
22
23
]
23
24
});
25
+
26
+ var logger = log4js.getLogger("hipchat");
27
+ logger.warn("Test Warn message");
28
+
24
29
@invoke
25
30
*/
26
31
You can’t perform that action at this time.
0 commit comments