-
-
Save tjfontaine/8309764 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| var net = require('net'); | |
| var server = net.createServer(function(conn) { | |
| console.log('client connection'); | |
| conn.destroy(); | |
| }).listen(function() { | |
| console.log('server listening', server.address()); | |
| net.connect(server.address()); | |
| }); | |
| var tracing = require('tracing'); | |
| tracing.on('net', 'server-connection', function() { | |
| console.log('tracing', arguments); | |
| server.close(); | |
| }); |
tjfontaine
commented
Jan 8, 2014
Author
I tried this, and yes got what I expected
var tracing = require('tracing');
tracing.on('http', 'server-request', function () {
console.log('----> (trace) New Requst');
});
var http = require('http');
var serv = http.createServer(function (req, res) {
res.write('HIII');
res.end();
})
serv.listen(8080);
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment