-Joseph
--
You received this message because you are subscribed to the Google Groups "ShareJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sharejs+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
On May 9, 2013 7:43 AM, "Adrian Geană" <geana....@gmail.com> wrote:
>
> Those live queries look neat. I'm curious on how it will scale on a large number of documents.
Me too, though there's a bunch of ways we can optimize it, at least for certain queries.
> I like the idea of using jsoneditor for JSON documents, but it would be great if changes are transformed to sub-document operations instead of full document replace operation. (I've noticed some p:[] ops in the console).
:} yep I totally cheated. I need to make a few changes to jsoneditor to make it generate ops, but the old JSON api code is still a bit broken. Its on my list.
-J
> Great work
>
>
> On Thursday, May 9, 2013 7:55:33 AM UTC+3, Joseph Gentle wrote:
>>
>> ShareJS's awesome pro style rewrite is coming along. Live queries are
>> working now, and the document class has about a billion new features
>> (including multiple editing windows on a page working, but sadly not
>> including cursors yet).
>>
>> Watch: http://www.youtube.com/watch?v=uDzME15UxVM
>>
>> The branch is here:
>> https://github.com/josephg/sharejs/tree/rewrite
>> If you want to play with it, the API has changed a fair bit (and is
>> still in a state of flux). So your milage may vary, and you should
>> keep this code far, faaaar away from production. I'll document the API
>> changes closer to release.
>>
>> Enjoy!
>> -Joseph
>
Its not a share document, and you don't want to persist it because you don't need to, and you don't want queries to show up in other queries.
Worst case, it reruns the query against the database when anything changes in the collection. But the server knows what op happened on what doc, so most queries can just be re-run against the particular doc that changed. By looking at the op itself, we can optimize for a bunch of standard cases as well (although limit queries will always have to hit the db I'm afraid)
I'm worried about how it'll scale, but its a good start.
-J
It depends how much you care about reliability. It'll be in beta in a month or so (we're deploying it) though I want to do plenty of testing, debugging and optimization work before I consider it stable.
Use it for a toy, but not for anything production critical.
-J
--