Use a caching table, and do the writes later.

 

 

On write:

Caching Table Append Record and new data.

 

20 minutes later:

Get all records for write with latest version.  Write to Datastore.

 

On Read:

Caching table is small so reads from it are fast and cheap. So.

 

Check Caching table for latest record, if found, return, if not found, do
read from datastore.

 

For even faster performance, ad a memcache layer for the reads and do a
check of caching table, then memcache then main datastore.

 

-Brandon

 

 

From: [email protected]
[mailto:[email protected]] On Behalf Of de Witte
Sent: Friday, February 25, 2011 1:43 AM
To: [email protected]
Subject: [google-appengine] High Replication Datastore and consistency
problem.

 

Hello,

We are developing the following datastore for a big application.

One table with 10.000.000 records.

The application has at any given time 40.000 active users.
These users make frequently adjustments to these records.
In rare cases, more than one user writes to a single record.

What happens if a specific user does four requests in a row to adjust a
single record. 

For example:

Entity Email with property content;

Request 1: get Email, add 'hello' to content, put Email.
Request 2: get Email, add ',how' to content, put Email.
Request 3: get Email, add ' are y' to content, put Email.
Request 4: get Email, add ' doing' to content, put Email.

How can I ensure that the content property has the value 'hello, how are y
doing' after the fourth request?

The entity group Email, has no parent.

Is this scenario strongly consistent?

-- 
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.

Reply via email to