summaryrefslogtreecommitdiff
path: root/node.gyp
diff options
context:
space:
mode:
authorBen Noordhuis <info@bnoordhuis.nl>2013-08-11 00:26:11 +0200
committerBen Noordhuis <info@bnoordhuis.nl>2013-09-06 05:51:42 +0200
commit756b6222956b5d25b2e7db81f4e79033a3a4d20e (patch)
treeeb03b6f0bf33c36e011858c4a31b10a6eaadfc19 /node.gyp
parent81655a224a36948291e1f21f03273b5b604b7e6a (diff)
downloadnode-new-756b6222956b5d25b2e7db81f4e79033a3a4d20e.tar.gz
src: add multi-context support
This commit makes it possible to use multiple V8 execution contexts within a single event loop. Put another way, handle and request wrap objects now "remember" the context they belong to and switch back to that context when the time comes to call into JS land. This could have been done in a quick and hacky way by calling v8::Object::GetCreationContext() on the wrap object right before making a callback but that leaves a fairly wide margin for bugs. Instead, we make the context explicit through a new Environment class that encapsulates everything (or almost everything) that belongs to the context. Variables that used to be a static or a global are now members of the aforementioned class. An additional benefit is that this approach should make it relatively straightforward to add full isolate support in due course. There is no JavaScript API yet but that will be added in the near future. This work was graciously sponsored by GitHub, Inc.
Diffstat (limited to 'node.gyp')
-rw-r--r--node.gyp5
1 files changed, 5 insertions, 0 deletions
diff --git a/node.gyp b/node.gyp
index 9e29ed12a4..3ff177ad98 100644
--- a/node.gyp
+++ b/node.gyp
@@ -116,6 +116,8 @@
'src/udp_wrap.cc',
'src/uv.cc',
# headers to make for a more pleasant IDE experience
+ 'src/env.h',
+ 'src/env-inl.h',
'src/handle_wrap.h',
'src/node.h',
'src/node_buffer.h',
@@ -124,6 +126,7 @@
'src/node_extensions.h',
'src/node_file.h',
'src/node_http_parser.h',
+ 'src/node_internals.h',
'src/node_javascript.h',
'src/node_root_certs.h',
'src/node_version.h',
@@ -139,6 +142,8 @@
'src/string_bytes.h',
'src/stream_wrap.h',
'src/tree.h',
+ 'src/util.h',
+ 'src/util-inl.h',
'deps/http_parser/http_parser.h',
'<(SHARED_INTERMEDIATE_DIR)/node_natives.h',
# javascript files to make for an even more pleasant IDE experience