From: "Daniel Bünzli" <daniel.buenzli@erratique.ch>
To: Diego Olivier Fernandez Pons <dofp.ocaml@gmail.com>
Cc: caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] SQL engine in OCaml with client side cache
Date: Sun, 29 Jan 2012 14:42:12 +0100 [thread overview]
Message-ID: <B57B8610DC5D49D0A36FE708419CC019@erratique.ch> (raw)
In-Reply-To: <CAHqiZ-Jra20HXK2ma-Sqzrw2srUcY61mHSkH3TufYtB9_0yM4A@mail.gmail.com>
Le dimanche, 29 janvier 2012 à 10:56, Diego Olivier Fernandez Pons a écrit :
> Therefore I thought I could add a "cache" on the client side, meaning an in-memory SQL database that would receive a big block of data from the server and work on it till the client writes a query that needs some data that is not available locally in which case it would request it from the server, etc.
>
> I haven't found anything like that ready-to-use, so I was considering reengineering existing OCaml code (database + web) and maybe compile it to JavaScript. I have control on the client so I can afford installing an OCaml runtime if needed albeit impractical though.
If you can afford to install recent browsers, on the javascript side.
Webdatabase [1] would have made your day but the spec has been withdrawn. It seems work along these lines was pursued in IndexedDB [2] but it may be a little bit early to use it.
If the dataset is not too huge and your queries are simple enough you may be able to hack a thin layer on top of webstorage [3]. But beware that this gives you no more than a persisent hashtable and I have no indication of the kind of performance you'd get. The advantage is that this is a candidate recommandation.
Note, I have used neither of those. Just know their existence.
Best,
Daniel
[1]
http://www.w3.org/TR/webdatabase/
http://caniuse.com/#search=websql
[2]
http://www.w3.org/TR/IndexedDB/
http://caniuse.com/#search=indexed
[3]
http://www.w3.org/TR/webstorage/ (http://www.w3.org/TR/webstorage/#storage)
http://caniuse.com/#search=webstorage
prev parent reply other threads:[~2012-01-29 13:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-29 9:56 Diego Olivier Fernandez Pons
2012-01-29 11:15 ` Gerd Stolpmann
2012-01-29 18:29 ` Diego Olivier Fernandez Pons
2012-01-29 20:16 ` Gerd Stolpmann
2012-01-29 23:26 ` Diego Olivier Fernandez Pons
2012-01-30 9:12 ` Gabriel Scherer
2012-01-31 15:04 ` Gerd Stolpmann
2012-01-29 11:39 ` Marc Weber
2012-01-29 13:42 ` Daniel Bünzli [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=B57B8610DC5D49D0A36FE708419CC019@erratique.ch \
--to=daniel.buenzli@erratique.ch \
--cc=caml-list@inria.fr \
--cc=dofp.ocaml@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox