79 Commits

Author SHA1 Message Date
David Glasser
a0e9fc3979 Add release files (0.6.0) to docs and all examples.
As part of the release process we'll update docs and all active
examples (other/unfinished examples can be updated as necessary). eg, first to
0.6.1-rc1, etc, and then to 0.6.1 when that is tagged from rc.
2013-03-19 15:13:54 -07:00
David Greenspan
a18a92e65f Deps.run => Deps.autorun 2013-03-11 12:17:39 -07:00
David Greenspan
b9c3e1fa30 port examples 2013-03-08 12:50:46 -08:00
David Glasser
9b486b3c9b Meteor.random -> Random.fraction
add Random.choice
2013-02-13 00:08:50 -08:00
David Glasser
d2ae5f7e1c Replace almost all uses of Meteor.uuid with Random.id. 2013-02-12 23:55:19 -08:00
David Glasser
0021307708 Updates to Python DDP client.
- Implement version handshake.

- Use a condition variable instead of sleep(0).

- Don't crash on 'added' with no fields.

- Include 'reason' when connection is closed.

- If our code throws an exception, make sure to print it before killing the main
  thread.

- Don't print a KeyboardInterrupt traceback on Ctrl-C or
  kill-due-to-connection-close. (ie, don't print two tracebacks if the thread
  throws.)
2013-02-12 11:40:43 -08:00
David Glasser
3f2aad7c0e Rename subscription "complete" to "ready" everywhere (including in the
protocol and the publisher API).

Also update examples/other/quiescence for ddp-pre1.
2013-01-30 13:34:58 -08:00
Naomi Seyfer
677a43fe19 Updated python DDP client to ddp-pre1 2013-01-17 15:23:24 -05:00
David Glasser
27d3073660 Make Meteor.autosubscribe a deprecated alias for Meteor.autorun.
Instead of a general client-side sub de-duping mechanism (which mostly existed
for the sake of autosubscribe, and causes issues with server-driven
unsubscribes), make Meteor.subscribe explicitly aware of reactivity.

Expose an "invalidated" flag on Meteor.deps.Context.

Guarantee that invalidation callbacks from different contexts will not be
interleaved at flush time. This has the implication that if you do

   context1.onInvalidate(function () {
     context2.invalidate();
   });

and this is the only way to invalidate context2, then context2's invalidation
callbacks will not be called until after *ALL* of context1's callbacks are
called. This allows us to be sure that the "unsubscribe, unless autorun tried to
re-create an identical sub" logic runs after the autorun function is rerun.
2013-01-15 17:07:03 -05:00
Nick Martin
0c64008499 Optimised images
Originally from https://github.com/meteor/meteor/pull/569

Reworked to:
- apply to soma.png, not soma.jpeg (file was previously misnamed).
- don't touch bootstrap's glyph image. It would cause conflicts later, and is not neighborly.
2013-01-08 20:52:30 -08:00
David Glasser
64253bc470 accounts-ui-viewer: use triple-stash for the inclusiong of checked="checked" to
avoid escaping the quotes.
2012-12-26 23:30:26 -08:00
Nick Martin
6fee95fc34 make static bigdata app to stress page load (merge box) 2012-12-12 22:01:09 -08:00
Nick Martin
ae07218515 Convert the benchmark to use Meteor.settings to load scenarios. 2012-12-11 00:17:28 -08:00
David Greenspan
11f98e0748 include jsparse-docs app in main repo
Under examples/unfinished.  Was in my personal repo.

This app displays a nicely-formatted full reference for the jsparse syntax tree.
2012-12-10 15:27:09 -08:00
Avital Oliver
0af26570c3 accounts-ui fixes related to the introduction of {{loggingIn}}
- Correctly position certain elements
- Reduce flicker/things moving around in various cases
- Force dropdown to open in case there is a message to display
2012-11-16 17:24:45 -08:00
Nick Martin
42fa76ccc1 Basic benchmark app. Very unfinished. 2012-11-15 22:56:59 -08:00
David Glasser
f8c54c4046 Overhaul quiescence, method callback timing, and login methods on the client.
- Data streamed from the server is quiesced on a per-object basis, not a global
  basis. We track which documents a method stubs modifies, and create individual
  snapshots ("server documents") of those documents rather than whole-Collection
  snapshots. Data writes from the server to documents not modified by stubs are
  applied immediately to the local cache; other writes are applied to the
  "server document" snapshots. Server documents are flushed to the local cache
  when all method stubs that wrote to the document have sent their "data write"
  message.  (We still do "full database" quiescence after a reconnect.)

- Instead of calling method callbacks as soon as the result is received, we wait
  until all data that precedes their "data done" message is flushed to the local
  cache. This way, method callbacks can see all of their results locally. (This
  applies to Collection mutator callbacks as well.) If this delay is
  unacceptable, you can also specify the onResultReceived option to
  Meteor.apply; this callback is given the method result as soon as it comes in,
  and there's no guarantee that the local cache is up to date.
  (This is a client-only change: server-side callbacks do not block on the
  write fence.)

- Methods invoked with the "wait" option to Meteor.apply now wait until all
  preceding methods are fully finished to be *sent*, not just to call their
  callbacks. ie, previous calls block the "wait" method in the same way that
  "wait" methods block subsequent calls.

- Remove Meteor.userLoaded and {{currentUserLoaded}}.
  Meteor.userId() is now set only at the point where Meteor.user() is fully
      loaded.
  Current user data is published via an unnamed subscription, not via
      "meteor.currentUser".
  Replace them with Meteor.loggingIn() and {{loggingIn}}, which become true
      as soon as the login method is sent (instead of only once it succeeds).
  In accounts-ui, move the spinny into the dropdown, because it now shows up
      before error messages would.

- Previously, if we received the "result" message from a method but no "data"
  message, and then disconnected and reconnected, quiescence would be
  permanently blocked. Now, not only do we allow the app to continue working,
  but we even guarantee that the method's callback will be called at the
  "reconnect quiescence" point.

- Remove reset function from the Store API (the interface between
      _LivedataConnection and Collection), and add a boolean "reset" argument to
      beginUpdate instead.
  Add saveOriginals/retrieveOriginals functions to the Store API (pass-through
      to minimongo implementation).
  Allow "replace" messages to be passed to the Store API's update function
      (in addition to set/unset).
  Allow Store API implementations (eg tinytest_client) to not specify all
      functions.

- Server-side tinytest results now stream into the result page instead of
  appearing all at once at the end.

- Rename fields and methods of Meteor._LivedataConnection as camelCase, and
  prepend all internal fields with _.

- Different Meteor._LivedataConnection objects now have separate
  _userIdListeners _ContextSets.

- Remove snapshot/restore functionality from Minimongo collections. (Individual
  queries still have result snapshots.) The "server documents" in
  Meteor._LivedataConnection serve the equivalent purpose.

- Meteor.loginWithToken's callback is now a "call with error on error, call
  with no args on success" callback like the other login callbacks.

- The test-only Meteor._LivedataConnection.onQuiesce function is removed.
  Every single use of it is now supported by normal method callbacks.
2012-11-14 18:10:08 -08:00
Avital Oliver
b1eb334d41 accounts-ui improvements
- Better behavior when in-line. Text around {{loginButtons}} does not move up and down when logging in and out
- In various cases, text underneath {{loginButtons}} no longer moves up and down when logging in
- Refactored the way we support right-aligned login dropdowns to not use a container div
- Use inline-block instead of float for the image inside the login buttons
- Generally use inline-blocks more correctly (rather than blocks inside inline-blocks)
- Some other small refactoring
2012-11-02 12:20:22 -07:00
David Greenspan
6d06e5486c accounts-ui-viewer: move dropdown to the right 2012-10-12 16:28:39 -07:00
David Greenspan
32edb4043f loginButtons halign -> align 2012-10-12 09:38:20 -07:00
David Greenspan
92ac9f1309 accounts-ui-viewer: allow testing of background color 2012-10-11 21:55:09 -07:00
David Greenspan
ea83ef4174 accounts-ui-viewer: update for halign 2012-10-11 21:54:56 -07:00
Avital Oliver
ed89815a33 accounts-ui: {{> loginButtons}} -> {{loginButtons}}
Also support {{loginButtons halign="right"}} for a dropdown that
hangs to the left
2012-10-11 19:50:09 -07:00
David Greenspan
09ed9ffeea accounts-ui-viewer tests spinner 2012-10-11 18:50:06 -07:00
David Greenspan
d5ccedf8c1 harness for viewing states of accounts-ui 2012-10-10 22:16:07 -07:00
David Glasser
5a01d9fe4d Meteor.Collection now takes its optional parameters ("manager" and some
undocumented ones beginning with _) in an options dictionary.

(For backwards compatibility it still supports passing the manager directly.)
2012-10-08 09:17:54 -07:00
David Glasser
71851fef89 Merge branch 'devel' into auth
Conflicts:
	app/meteor/skel/.meteor/packages
	examples/leaderboard/.meteor/packages
	packages/livedata/livedata_connection.js
2012-10-01 20:07:27 -07:00
David Greenspan
be6b876d53 remove trailing comma 2012-09-30 15:30:59 -07:00
David Greenspan
9dce7c7cfa rename tabs to JS Lex and JS Parse 2012-09-30 15:05:32 -07:00
David Greenspan
8f23d52618 rename example jsparse-demo -> parse-inspector 2012-09-30 15:04:55 -07:00
David Greenspan
6686d40526 include comments in jsparse AST 2012-09-30 00:42:04 -07:00
David Greenspan
3201fe5180 jsparse demo improvements (lexer tab) 2012-09-29 21:33:19 -07:00
David Greenspan
b995d4751a add preserve-inputs package to skel and more examples 2012-09-28 13:23:30 -07:00
Avital Oliver
ee922de1c2 Merge branch 'devel' into auth
Conflicts:
	packages/livedata/livedata_server.js
2012-09-21 10:59:48 -07:00
David Greenspan
886d657afe Merge branch 'jsparse' into devel
Adds the "jsparse" JavaScript parser as an internal package.

At some point jsparse will get proper docs and become a public
package.  For now, it's basically complete and has unit tests,
so it meets the bar for an internal package.  It will be used
by the new docs tool.
2012-09-19 11:45:02 -07:00
David Glasser
2fedd2adfc Merge branch 'devel' into auth
Conflicts:
	packages/livedata/livedata_common.js
	packages/livedata/livedata_connection.js
	packages/livedata/livedata_server.js
	packages/mongo-livedata/collection.js
2012-09-17 14:42:10 -07:00
David Glasser
5e622215ba Change all publicly documented APIs to use camelCase.
For now, the old names still work as well.

This includes:
  - Meteor.isServer/isClient
  - this.isSimulation in methods
  - Context.onInvalidate
  - Meteor.status().retryCount/retryTime

Remove old backwards-compatibility "Sky" alias for "Meteor".

Update all examples in the docs to use camelCase.

Delete unused docs/client/projects.html file.
2012-09-17 14:26:45 -07:00
David Greenspan
34b4ebbf22 create JSParser 2012-09-12 14:11:28 -07:00
David Greenspan
6e5e7497f0 Lexeme object 2012-09-12 13:04:19 -07:00
David Greenspan
a6bd5747b2 ParseNode object 2012-09-11 18:03:29 -07:00
David Greenspan
f1379b8ec9 demo tweaks 2012-09-11 16:49:47 -07:00
David Greenspan
c63278332b AST => tree 2012-09-11 16:49:47 -07:00
David Greenspan
d6370e762a tweaks, node naming 2012-09-11 16:49:47 -07:00
David Greenspan
ef62683280 none => empty 2012-09-11 16:49:47 -07:00
David Greenspan
42675e5c02 "variables" statement => "var" statement 2012-09-11 16:49:47 -07:00
David Greenspan
48c62ea850 further demo tweaks 2012-09-11 16:49:47 -07:00
David Greenspan
cbfad7f578 UI tweaks 2012-09-11 16:49:46 -07:00
David Greenspan
ce65ffede8 whitespace fixes 2012-09-11 16:49:46 -07:00
David Greenspan
cad29bd0b1 css tweaks 2012-09-11 16:49:46 -07:00
David Greenspan
6f46d17a54 change starting example 2012-09-11 16:49:46 -07:00