Commit Graph

21448 Commits

Author SHA1 Message Date
Ben Newman
a756af487b Merge branch 'devel' into release-1.7.1 2018-07-18 12:42:01 -04:00
Ben Newman
af26e8b052 Merge pull request #9558 from jamesmillerburgess/accounts-remove-underscore
Modernize accounts packages
2018-07-18 09:33:28 -07:00
James Burgess
e56c18f26b Modernize binary-heap package (#9615) 2018-07-18 08:07:22 -07:00
Ben Newman
ea04dde68a Merge branch 'devel' into accounts-remove-underscore 2018-07-18 08:03:23 -07:00
zebra-lucky
a8c6701c60 Implement Mongo 3.4 Decimal128 in packages/non-core/mongo-decimal (#9662) 2018-07-18 07:59:54 -07:00
James Burgess
35b850d6f5 Cache npm dependencies from meteor packages in CircleCI (#9785) 2018-07-18 07:56:39 -07:00
Ben Newman
50b6751728 Merge pull request #9814 from toinevk/devel
Switch Meteor's headless browser tests from PhantomJS to Headless Chrome
2018-07-18 07:54:44 -07:00
Ben Newman
d8042c8fa9 Merge pull request #10053 from nathan-muir/nm-ddp-perf
ddp-server: replace usage of Object with Map & Set
2018-07-18 07:53:44 -07:00
Joachim Achtzehnter
093f9458a1 Request less than 4GB on 32-bit platforms (#10081)
A recent commit added a flag to request 4GB space for node, which
causes an immediate segmentation fault on 32-bit Linux.
2018-07-18 07:52:42 -07:00
Ben Newman
121eb30c90 Shorten initial README.md description for inter-process-messaging. release/METEOR@1.7.1-beta.19 2018-07-17 21:12:46 -04:00
Ben Newman
fe45f24c8f Bump package versions for 1.7.1-beta.19 release. 2018-07-17 21:02:07 -04:00
Ben Newman
fc1c762ad5 Bump $BUNDLE_VERSION to 8.11.3.6 before rebuilding dev bundle. 2018-07-17 21:00:18 -04:00
Ben Newman
50b44f6465 Update meteor-babel to version 7.0.0-beta.54. 2018-07-17 20:35:37 -04:00
Ben Newman
ff8cee9e4e Update npm to version 6.2.0.
The pacote dependency (a small fork of which we maintain) remains at
version 8.1.6.
2018-07-17 20:13:55 -04:00
Ben Newman
d7e489d5d5 Merge pull request #10077 from meteor/inter-process-messaging
Use listener API for communication between build/server processes.
2018-07-17 15:12:14 -07:00
Ben Newman
7d25b592b6 Use ARSON to encode and decode IPC payloads and results. 2018-07-17 16:44:59 -04:00
Ben Newman
5ea442bb12 Update packages/inter-process-messaging/README.md. 2018-07-17 16:44:58 -04:00
Ben Newman
f4946306c0 Make IPC system more testable, and implement some basic tests. 2018-07-17 16:44:58 -04:00
Ben Newman
eceb3b0f57 Silence UnhandledPromiseRejectionWarning in exit handler. 2018-07-17 16:44:58 -04:00
Ben Newman
9faaddd641 Handle child process 'exit' event in IPC system. 2018-07-17 13:24:02 -04:00
Ben Newman
393196eb93 Remove parent/child terminology from the IPC system.
Every process is potentially the child of some other process and the
parent of zero or more child processes of its own, so it's confusing to
use terminology that always treats the current global.process as a
"parent" process, or to include PARENT and CHILD in the message types.

Instead, this new implementation uses message types MESSAGE, RESPONSE,
PING, and PONG, and refers to `process` and `otherProcess` objects,
with the caveat that sometimes `process === otherProcess`, because
`process.send` can be used to send messages to the parent process.

Instead of relying on the child to send a special CHILD_READY message to
the parent when it's ready to receive messages, the sending process polls
the receiving process with a preflight PING message, and the receiving
process immediately responds with a PONG when ready.
2018-07-17 13:11:48 -04:00
Ben Newman
692b533d49 Extract IPC type strings into a shared module. 2018-07-17 10:27:00 -04:00
Ben Newman
2450ffe84d Remove unreliable modification of Autoupdate versions from self-test. 2018-07-16 18:59:51 -04:00
Ben Newman
77ed148614 Use listener API for communication between build/server processes.
Fixes #10073, per
https://github.com/meteor/meteor/issues/10073#issuecomment-405290391

While thinking about this bug, I realized that sending IPC messages to
specific packages in the server process was much less flexible than
sending messages based on an arbitrary topic string, since the topic
string approach allows both `autoupdate` and `dynamic-import` to listen
for the same message.

The topic string approach calls for a listener interface like
`onMessage(topic, callback)`, which elegantly replaces the previous
approach of requiring packages to export a single `onMessage` function.

However, because the `meteor` package does not have access to the module
system, implementing the `onMessage` listener interface in the `meteor`
package would have required exposing an API like `Meteor.onMessage(topic,
callback)`, which has an unpleasant global smell to it. Instead, the
`onMessage` function should be explicitly imported (using the module
system) from a less-generically-named package.

Since I knew I was going to have to move the message dispatch logic out of
the `meteor` package, I decided to create a new package called
`inter-process-messaging` to implement the parent/child components of the
IPC system.
2018-07-16 18:59:50 -04:00
Toine van Kampen
92b72bc46b Fix Failing Tests
Ensure Hot Code Push and Package Tests account for possible multiple runs.
2018-07-15 10:17:01 +10:00
Ben Newman
547b1675b7 Bump package versions for 1.7.1-beta.18 release. release/METEOR@1.7.1-beta.18 2018-07-13 03:50:39 -04:00
Ben Newman
34bbbcb0f9 Calculate autoupdate versions correctly in cordova/builder.js.
Follow-up to the recent rewrite of autoupdate:
fe9e4035f9

Should fix #10067.
2018-07-12 11:57:09 -04:00
Ben Newman
e2e0f71b14 Bump package versions for 1.7.1-beta.17 release. release/METEOR@1.7.1-beta.17 2018-07-11 20:23:26 -04:00
Ben Newman
244fd2a677 Replace Package._on(name, callback) with Package._promise(name).
https://github.com/meteor/meteor/pull/10055#discussion_r201855997

As I explained in this comment, Package._on(packageName, callback) was a
bad API because it never called the callback if the package was not
installed, which caused any app not using the autoupdate package to get
stuck trying to communicate with the autoupdate package.
2018-07-11 19:37:44 -04:00
Ben Newman
52eb3590b7 Bump package versions for 1.7.1-beta.16 release. release/METEOR@1.7.1-beta.16 2018-07-11 16:31:19 -04:00
Ben Newman
92f6835d2d Bump $BUNDLE_VERSION to 8.11.3.5 before rebuilding dev bundle. 2018-07-11 16:10:33 -04:00
Ben Newman
75443b6995 Merge branch 'devel' into release-1.7.1 2018-07-11 16:10:06 -04:00
Ben Newman
1818150ad6 Bump dev_bundle/lib/node_modules/@babel/runtime to v7.0.0-beta.53. 2018-07-11 16:09:12 -04:00
Ben Newman
60e29707d4 Bump $BUNDLE_VERSION to 8.11.3.4 before rebuilding dev bundle. 2018-07-11 16:07:11 -04:00
Ben Newman
05e7aebef7 Merge branch 'devel' into release-1.7.1 2018-07-11 15:52:05 -04:00
Ben Newman
4b905ed51e Update reify npm package to version 0.16.4. 2018-07-11 15:46:51 -04:00
Ben Newman
098ce3f5db Update reify npm package to version 0.16.3.
This already landed on release-1.7.1, but I've cherry-picked it back onto
devel to avoid confusion.
2018-07-11 15:44:29 -04:00
Ben Newman
2765238a29 Update meteor-babel to version 7.0.0-beta.53. 2018-07-11 15:29:45 -04:00
Jesse Rosenberger
a0578e90e3 Pass the --phantom flag on all self-test runs, to always test Phantom.
Without the `--phantom` flag passed to the `meteor self-test` command, the
client tests within those self-test test definitions will only be run on
Chrome Headless.

We might want to consider making it the default, so it runs without an
additional argument on local development as well, but this will make sure
that these important Phantom tests run in CircleCI to ensure we're testing
both modern and legacy browsers (of which the later group includes
PhantomJS, in all its "legacy" glory).

cc @hwillson @benjamn for input.
2018-07-11 12:17:35 -07:00
Ben Newman
c82141cbaa Merge pull request #10055 from meteor/wip-delay-building-legacy-bundle
Delay building web.browser.legacy bundle until after development server restarts.
2018-07-11 14:34:04 -04:00
Jesse Rosenberger
382e0f0762 Remove dependency installation which is now bundled into CircleCI Docker image.
These are now built into the CircleCI image we already use
(meteor/circleci), thanks to the changes in meteor/circleci#1.
2018-07-11 10:41:15 -07:00
Ben Newman
05ffaa504b Force older autoupdate clients to reload. 2018-07-11 13:08:33 -04:00
Jesse Rosenberger
f7752a071a Merge branch 'devel' into HEAD 2018-07-11 09:29:26 -07:00
Ben Newman
41e2615424 Fix tests by awaiting newly-async WebApp.staticFilesMiddleware. 2018-07-11 10:32:29 -04:00
Ben Newman
cacace3bcb Avoid nested Profile.run calls in watch.sha{1,512} functions. 2018-07-11 10:08:57 -04:00
Ben Newman
1387473cf5 Pause requests for the legacy bundle while rewriting it.
This is the solution I came up with for the problems I described here:
https://github.com/meteor/meteor/pull/10055#issuecomment-403219805
2018-07-10 21:17:14 -04:00
Ben Newman
4b17a0b760 Allow sending IPC messages from build process to server process.
Instead of having every message consumer listen to every message and act
on the ones that seem relevant to its interests, we now have a single
process.on("message", callback) hook that can dispatch messages to
different Meteor packages running in the server process.

Receiving packages should export an onMessage function. The onMessage
function may be async, and its result will be delivered back to the build
process as the result of the sendMessage Promise.
2018-07-10 21:17:14 -04:00
Ben Newman
2c567091c8 Explicitly add uuid package to dev_bundle/lib/node_modules.
This package is already importable because it's a dependency of request,
npm, and http-signature, but it's a good idea to depend on it explicitly
just in case those packages stop depending on it in the future.
2018-07-10 21:17:14 -04:00
Ben Newman
213d4389c2 Implement Package._on(name, callback) to intercept Package._define. 2018-07-10 21:17:14 -04:00
Ben Newman
99b79dc00f Include hash of minimum modern versions in autoupdate versions. 2018-07-10 17:43:28 -04:00