Skip to content

Commit

Permalink
Catch more stasd exceptions
Browse files Browse the repository at this point in the history
Closes #167
  • Loading branch information
Sandro Santilli committed Mar 4, 2014
1 parent 18f8642 commit fe41b04
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
2 changes: 1 addition & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Version 0.19.4

Enhancements:

- Catch profiler exceptions (#166)
- Catch statsd exceptions (#166, #167)

Version 0.19.3
2014-03-04
Expand Down
18 changes: 15 additions & 3 deletions lib/windshaft/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -786,8 +786,12 @@ module.exports = function(opts){
if ( err ) throw err;
app.getTileOrGrid(req, res, this); // legacy get map tile endpoint
},
function finish(err, req_ret, res_ret, tile, headers) {
function finalize(err, req_ret, res_ret, tile, headers) {
app.finalizeGetTileOrGrid(err, req, res, tile, headers);
return null;
},
function finish(err) {
if ( err ) console.error("windshaft.tiles: " + err);
}
);
});
Expand Down Expand Up @@ -1192,8 +1196,12 @@ module.exports = function(opts){
if ( err ) throw err;
app.getTileOrGrid(req, res, this); // map api map tile endpoint
},
function finish(err, req_ret, res_ret, tile, headers) {
function finalize(err, req_ret, res_ret, tile, headers) {
app.finalizeGetTileOrGrid(err, req, res, tile, headers);
return null;
},
function finish(err) {
if ( err ) console.error("windshaft.tiles: " + err);
}
);
});
Expand All @@ -1216,8 +1224,12 @@ module.exports = function(opts){
if ( err ) throw err;
app.getTileOrGrid(req, res, this); // map api map layer tile endpoint
},
function finish(err, req_ret, res_ret, tile, headers) {
function finalize(err, req_ret, res_ret, tile, headers) {
app.finalizeGetTileOrGrid(err, req, res, tile, headers);
return null;
},
function finish(err) {
if ( err ) console.error("windshaft.tiles: " + err);
}
);
});
Expand Down

0 comments on commit fe41b04

Please sign in to comment.