0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

46 Commits

Author SHA1 Message Date
Rich Trott
4bb529d972 benchmark: use strict mode
Apply strict mode to benchmark code.

PR-URL: https://github.com/nodejs/node/pull/5336
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-02-22 11:09:26 -08:00
isaacs
88befa6021 bench: Make http easier to profile
Do not run the http/simple.js server in a child process.

Fix #4831
2013-02-25 17:47:28 -08:00
isaacs
536ce44689 bench: http benchmarks
Also: make http_simple less chatty
2013-02-19 14:14:31 -08:00
Ben Noordhuis
ba407ce410 bench: use res.end() for chunked encoding
Use res.end() for the final chunk so we can benchmark the 'hot path' shortcut
in lib/http.js that packs the headers and the body into a single packet.
2012-12-20 11:44:10 +01:00
Bert Belder
4ddafbd563 Benchmark: add /unicode/nnn bench to http_simple.js 2012-05-09 03:56:09 +02:00
Bert Belder
7f68f256cf Benchmark: clean up http_simple.js 2012-05-09 03:56:07 +02:00
isaacs
45c1d4f96f Add switches to http_simple bench to use domains 2012-04-17 13:14:55 -07:00
Ben Noordhuis
8b2abed03d bench: add /echo endpoint to http_simple
Copies the POST request data verbatim into the response body.
2011-12-30 02:03:10 +01:00
Ryan Dahl
16e1d5b5ce Remove uname and git-rev detection from http_simple.js 2011-10-12 12:29:40 -07:00
Ryan Dahl
f018be3b5f Print libuv counters after http_simple exits 2011-10-06 15:02:27 -07:00
Ben Noordhuis
63607a0304 bench: make number of response body chunks configurable in http_simple 2011-08-17 23:26:23 +02:00
Ben Noordhuis
d72c6940f8 bench: make http_simple send chunked encoding if requested 2011-08-17 20:39:20 +02:00
Ryan Dahl
08bec7ab0a Remove debugger statement from http_simple.js
results in slow bench
2011-01-06 18:07:50 -08:00
Ryan Dahl
62e0ca05a6 debugger: Disable/Enable raw mode for child 2010-12-30 15:46:47 -08:00
Ryan Dahl
ff456b3886 Add 'make bench' script 2010-10-13 16:20:24 -07:00
Ryan Dahl
cdde22a27d Improve benchmark/http_simple.js 2010-10-13 14:30:50 -07:00
Blake Mizerany
8c8534046c fix whitespace errors 2010-06-29 23:59:24 -07:00
Ryan Dahl
444b33584d Remove switch-replace residue 2010-06-24 09:37:36 -07:00
Ryan Dahl
ba792ea202 :%s/sys.puts/console.log/g
and there was much rejoicing
2010-06-23 20:05:29 -07:00
Ryan Dahl
ab723d022d Add buffer response to http_simple.js 2010-05-04 22:35:55 -07:00
Ryan Dahl
99984772df Allow different ports for http_simple.js 2010-05-02 17:26:18 -07:00
Ryan Dahl
ac3bc2ed41 Simplify GC idle notification
In particular, don't leave the timeout running when the heap is fully
compacted.
2010-04-15 01:30:58 -07:00
Ryan Dahl
b36f11d7b5 Set old/new from benchmark script args 2010-04-09 10:42:20 -07:00
Ryan Dahl
50c70ac714 Update stream API: forceClose() -> destroy(), close() -> end() 2010-04-08 12:24:29 -07:00
Ryan Dahl
62277ab79b Support both old and new HTTP closing APIs in benchmark program 2010-04-08 01:00:35 -07:00
Ryan Dahl
0281e1acf6 Fix benchmark script for testing both old and new version 2010-04-07 16:19:50 -07:00
Ryan Dahl
1b758ef268 Allow stream to write on close 2010-04-05 16:50:05 -07:00
Ryan Dahl
b80f6e9ed1 http2 now default 2010-03-19 19:52:09 -07:00
Ryan Dahl
1762abcece http2 now passes all tests 2010-03-18 15:49:42 -07:00
Ryan Dahl
b07f2e25f4 Update http2 for new stream API 2010-03-09 12:00:06 -08:00
Ryan Dahl
04999ef969 Remove -Werror from deps/v8/SConstruct
-_-
2010-03-08 18:04:59 -08:00
isaacs
c488e5775a Remove process.mixin dependencies from benchmark scripts 2010-03-08 17:57:38 -08:00
Benjamin Thomas
b1b84960ce Rename writeHeader to writeHead 2010-02-25 13:01:21 -08:00
Ryan Dahl
12d78cd1df Rename sendHeader to writeHeader; allow reasonPhrase 2010-02-21 16:53:49 -08:00
Ryan Dahl
7c1c89fc29 Update benchmark script to new API 2010-02-17 15:37:12 -08:00
Ryan Dahl
ae85d9af97 API: Make request/response object closer to stream interface
- sendBody() renamed to write()
- 'body' event renamed to 'data'
- 'complete' event renamed to 'end'
2010-02-16 22:16:29 -08:00
Ryan Dahl
8e0dad4a27 Update http benchmark script to new url api. 2010-01-10 23:00:58 -08:00
Ryan Dahl
54c8ea5ea2 Fix http_simple server for new API 2009-11-06 12:53:27 +01:00
Ryan Dahl
d582599c14 Upgrade benchmark scripts for new module API 2009-10-31 20:06:46 +01:00
Ryan Dahl
ad0a4cefb8 Namespace EVERYTHING under process; introduce GLOBAL
http://groups.google.com/group/nodejs/browse_thread/thread/1034fd2ad2cd93e8
2009-10-29 23:36:41 +01:00
Ryan Dahl
04e53cab90 Rename node.libraryPaths to require.paths
to be more inline with CommonJS.
2009-10-25 22:51:57 +01:00
Ryan Dahl
8185e1fd25 Remove include() add node.mixin()
include() should not be used by libraries because it will pollute the global
namespace. To discourage this behavior and bring Node more in-line with
the current CommonJS module system, include() is removed.

Small scripts like unit tests often times do want to pollute the global
namespace for ease. To avoid the boiler plate code of

  var x = require("/x.js");
  var foo = x.foo;
  var bar = x.bar;

The function node.mixin() is stolen from jQuery's jQuery.extend. So that it
can be written:

  node.mixin(require("/x.js"));

Reference:
http://docs.jquery.com/Utilities/jQuery.extend
http://groups.google.com/group/nodejs/browse_thread/thread/f9ac83e5c11e7e87
2009-10-05 15:46:31 +02:00
Ryan Dahl
f6657c3c9d Move http library to /http.js 2009-09-28 12:36:36 +02:00
Ryan
316e2833f0 Use flat object instead of array-of-arrays for HTTP headers.
E.G. { "Content-Length": 10, "Content-Type": "text/html" } instead of
[["Content-Length", 10], ["Content-Type", "text/html"]].
The main reason for this change is object-creation efficiency.

This still needs testing and some further changes (like when receiving
multiple header lines with the same field-name, they are concatenated with a
comma but some headers ("Content-Length") should not be concatenated ; the
new header line should replace the old value).

Various thoughts on this subject:
http://groups.google.com/group/nodejs/browse_thread/thread/9a67bb32706d9efc#
http://four.livejournal.com/979640.html
http://mail.gnome.org/archives/libsoup-list/2009-March/msg00015.html
2009-08-23 12:32:49 +02:00
Ryan
70fe920fb5 Use events for all HTTP messages.
This is a rather large refactor! Mostly for the better side. I've had to
remove some functionality like req.interrupt(). A lot of other work is left
messy or incomplete.
2009-06-28 19:08:26 +02:00
Ryan
61fcbb1cd6 Add benchmark dir with ruby script 2009-06-18 14:36:30 +02:00