Skip to content

Google App Engine Datastore

1337 edited this page Jun 25, 2012 · 5 revisions

The Google App Engine datastore (DS) has advantages and disadvantages, both of which will greatly affect how you formerly design a relational database (DB).

  1. Everything needs to be indexed to be found. Composite indexes (searches involving more than one field) are expensive to store, so avoid them unless you are sure these composite fields will remain small.
  2. Reads cost money, and writes even more. You can't write everything for the sake of it; you can't read everything straight from the DS. Memcache is your friend, but make sure it is kept fresh.
  3. There are no primary keys. You can easily duplicate something by accident.
  4. There are no unique fields. To implement a unique field, you need to fetch every object saved from the past to make sure nothing is already there.

Clone this wiki locally