Hey there,
we're thinking about using Gears for a generally simple project, which
should allow users to enter data for about 20-25 text fields for each
database entry (offline). Additionally, it should be possible to add
pictures to those database entries. Maybe around 0-4 images. This
should be synchronized with a web server when online again.
The database has already 150,000 entries, so there might be around
200,000x25 = 5m cells and around 800,000 images to be cached for
offline access.
- Can SQLite handle this amount of data, is it still fast?
- Can Gears handle caching for around 800,000 images in the (Managed)
ResourceStore? I tried to generate this manifest file using the
following php code:
[php]<?php
//ini_set("memory_limit", "64M"); // try
$manifest = new stdClass();
$manifest->betaManifestVersion = 1;
$manifest->version = 1;
$manifest->entries = array();
for ($i = 0; $i < 800000; ++$i) {
$entry = new stdClass();
$entry->url = "image$i.php";
$manifest->entries[] = $entry;
}
echo json_encode($manifest);
?>[/php]
This killed the server (Apache crash).
Does it make sense to split those entries to f.e. 800 files? Does it
make sense to use the ManagedResourceStore? The images probably won't
change after submitting, so is it a problem for the ResourceStore to
handle them? How does Gears save those Resources? SQLite, file system?
Another point would be the images. Is it possible for the canvas API
(is it already available?) to resize the images before sending them
with HttpRequest API to the server?
Is there a plan to allow BLOBs being stored in the SQLite database?
Thanks in advance,
Chris