W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2010

Re: Replacing WebSQL with a Relational Data Model.

From: Keean Schupke <keean@fry-it.com>
Date: Wed, 27 Oct 2010 12:12:13 +0100
Message-ID: <AANLkTinsgj14nt9iQDBo+KHaf=bNA_Vj08uevSHxeVnz@mail.gmail.com>
To: Jeremy Orlow <jorlow@chromium.org>
Cc: Nathan Kitchen <w3c@nathankitchen.com>, nathan@webr3.org, public-webapps@w3.org, Jonas Sicking <jonas@sicking.cc>, Arthur Barstow <art.barstow@nokia.com>
Hi Jeremy,


>> Is this fast enough? Power users have 5000 contacts, Just getting HTML5 to
>> produce a scrolling list that long that is fast enough to fling properly on
>> a mobile device is a struggle.
>>
>
> This is typically addressed by
> http://en.wikipedia.org/wiki/Flyweight_pattern whether or not the backing
> data is loaded into memory.  But it's worth noting that the types of
> workloads Google is hoping to do eventually is store tens of thousands of
> emails and as full of an on-line experience as possible.  This is beyond the
> limit where SQLite starts to choke in our experience.
>

Actually the problem with this is the internal memory usage by the browser
to have a single page with 5000 divs in a list, each of which has a layout
with say 20 elements, so about 100,000 elements. The memory used by the
browser for the DOM tree (on a mobile device) and rendering is the problem,
so I don't think (correct me if I am wrong) the Flyweight pattern can help.

To get round this we only create enough divs to fill the screen, and cycle
them round by catching onscroll events. This is just about fast enough - but
was something I had to implement for our web developers as a library due to
the complexity.


Cheers,
Keean.
Received on Wednesday, 27 October 2010 11:12:48 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:41 GMT