mirror of
https://github.com/http-party/node-http-proxy.git
synced 2025-12-08 20:59:18 +00:00
Updated Routing proxy with access logging (markdown)
parent
9165d80955
commit
ff4bb14225
@ -15,7 +15,7 @@ One of the useful methods of running http-proxy is as a routing proxy. The follo
|
||||
router.proxyRequest(req,res);
|
||||
});
|
||||
|
||||
proxy.listen(3000, function() { console.log("Routing proxy listening on " + proxy.addresss().port); });
|
||||
proxy.listen(3000, function() { console.log("Routing proxy listening on " + proxy.address().port); });
|
||||
|
||||
the above example uses console.log, but you could use any logging library, e.g. winston, to create access logs with info from req and res.
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user