Search code examples
sqlgoogle-app-enginecloudbigtable

GAE Cloud SQL and High Replication Datastore


With HRD and BigTable, you are forced to deal with eventual consistency for all queries that are not ancestor queries. Your code has to be robust enough to cope with the fact that the results may be stale.

With Google's launching of Cloud SQL, they put in a disclaimer: ( https://developers.google.com/cloud-sql/faq#hrapps )

"We recommend that you use Google Cloud SQL with 
High Replication App Engine applications. While you can use use 
Google Cloud SQL with applications that 
do not use high replication, doing so might impact performance."

What does this mean? Does this mean that there are the same eventual consistency issues using SQL with HRD? There is no concept of entity groups in SQL, however could this mean that particular SQL queries in particular circumstances deliver stale results?

This would mean that Google's implementation of the SQL atomic transactional contract would be broken and SQL would not function as users of relational databases would expect. If this is not the case, what are the concerns for having a master/slave or HRD model with SQL and why would Google give you the option of choosing a model with poorer performance?


Solution

  • (from forum)

    The Cloud SQL and Data store systems are independent. You can use one or both as you see fit for your app.

    We recommend using HRD apps because that type of app will be colocated with Cloud SQL. Master slave apps are served from a different set of datacenters where cloud sql does not have presence. It will work but it will be slower.