News for hackers. Stuff that matters.
Re:Node.js in Flame Graphs by ecaron on Wednesday November 19, 2014 @12:12PM (#8631206)
My biggest takeaway from this article is that Netflix is moving from Express to Restify, and I look forward to watching the massive uptick this has on https://github.com/mcavage/node-restify/graphs/contributors
Re:Node.js in Flame Graphs by sadkingbilly on Wednesday November 19, 2014 @12:47PM (#8631429)
Yes, but their original bug was from dynamically loading routes from an external source. I don't see how Express is to blame for this. Moving to Restify is not a solution, but they state having different reasons for moving (support for bunyan logging? But Express already supports this too).
Re:Node.js in Flame Graphs by ecnahc515 on Wednesday November 19, 2014 @01:01PM (#8631517)
the bug was related to dynamically loading routes, but the true cause was that express allowed duplicate handlers. They were loading routes dynamically correctly, that wasn't a problem, it was that when doing that express let them duplicate routes.
Re:Node.js in Flame Graphs by sisk on Wednesday November 19, 2014 @09:20PM (#8634058)
That's a feature.

From the API docs:

> Multiple callbacks may be given; all are treated equally, and behave just like middleware. The only exception is that these callbacks may invoke next('route') to bypass the remaining route callback(s). This mechanism can be used to perform pre-conditions on a route, then pass control to subsequent routes if there's no reason to proceed with the current route.

Re:Node.js in Flame Graphs by jonny_eh on Wednesday November 19, 2014 @02:42PM (#8632152)
If they were loading duplicate routes, how was it they were "loading routes dynamically correctly"?
Re:Node.js in Flame Graphs by gaving on Wednesday November 19, 2014 @03:39PM (#8632469)
Re:Node.js in Flame Graphs by dagw on Wednesday November 19, 2014 @05:17PM (#8633028)
While I kind of agree the restify gives you "almost nothing" when compared to some larger frameworks, in my experience "almost nothing" is basically all I need from my framework when writing REST APIs and restify has had me covered every time.