This repository has been archived by the owner on Sep 17, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Working version - both exceptions and logs
- Loading branch information
martinrusev
committed
Nov 9, 2011
1 parent
5c4e352
commit 67e81e1
Showing
3 changed files
with
94 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
var Amon = require('./lib/amon').Amon; | ||
|
||
Amon.log('node.js unset message') | ||
Amon.log('node.js debug message', 'debug') | ||
Amon.log('node.js warning message', 'warning') | ||
Amon.log('node.js info message', 'info') | ||
|
||
process.addListener('uncaughtException', function(err) { | ||
Amon.handle(err); | ||
}); | ||
|
||
//try { | ||
//throw new Error("Test Error 1"); | ||
//} catch(error) { | ||
//console.log("Error occurred ", error.message); | ||
//Amon.handle(error); | ||
//} | ||
|
||
|
||
throw new Error("Test Error 2"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters