Skip to content

Commit

Permalink
lib/server/http.js && test/http.js:
Browse files Browse the repository at this point in the history
- HTTP_Router():
  - Handle Experimental checkExpectations handler, check:
    - nodejs/node-v0.x-archive#4651
    - faridnsh/node@3227160
  - next(): capture exception and handle errors passed as a parameter
  - improve 404 Not Found error handler
  - provide 500 Internal Server Error handler with stack trace
  - Streamline http_handlers, flatening options into each handler

- serve_http_servers():
  - Streamline http_handlers, flatening options into each handler
  - http_handlers can alternatively be a function providing a handler for the request listener only
  - options can now provide a default route and default HTTP methods
  - document with plenty of examples

- serve(): use new serve_http_servers() handlers format

- test/http.js:
  - Make a handler that does not receive the next() parameter, because errors will be handled by Connect
  - provide /passport route to test/passport.js server
  - use new serve_http_servers() API using the connect application function for http_handlers
  - cleanup
  • Loading branch information
uiteoi committed Apr 16, 2014
1 parent c173617 commit 1035e83
Show file tree
Hide file tree
Showing 2 changed files with 289 additions and 97 deletions.
Loading

0 comments on commit 1035e83

Please sign in to comment.