{"id":35,"date":"2008-04-14T03:42:03","date_gmt":"2008-04-14T03:42:03","guid":{"rendered":"http:\/\/robubu.com\/?p=35"},"modified":"2008-04-14T03:42:03","modified_gmt":"2008-04-14T03:42:03","slug":"scaling-databases-and-googles-app-engine","status":"publish","type":"post","link":"https:\/\/robubu.com\/?p=35","title":{"rendered":"Scaling Databases and Google&#8217;s App Engine"},"content":{"rendered":"<p><a href=\"http:\/\/blog.labnotes.org\/2007\/09\/20\/read-consistency-dumb-databases-smart-services\/\">Assaf Arkin<\/a>: <i>if anything I wrote sounds vaguely familiar because you somehow managed to dumb your RDBMS into storing structured data in BLOBs, added versions and timestamps on all records, grappled with minimizing transactions and locks, denormalized data like there\u2019s no tomorrow, or relied too much on a message queue, then time to rethink. Are you using a hammer to polish your china? (Tip: not a good idea, invest in soft cloth)<\/p>\n<p><\/i>I know I am late (particularly as an IBMer) to the whole <a href=\"http:\/\/incubator.apache.org\/couchdb\/\">couchDB<\/a> \/ <a href=\"http:\/\/labs.google.com\/papers\/bigtable.html\">bigtable<\/a> <a href=\"http:\/\/jhingran.typepad.com\/anant_jhingrans_musings\/2007\/12\/simpler-db.html\">thing<\/a>, but I have to admit that until I read Assaf&#8217;s article I didn&#8217;t really understand what all the fuss was about. <\/p>\n<p>I also didn&#8217;t understand the fuss about <a href=\"http:\/\/code.google.com\/appengine\/\">google&#8217;s app engine<\/a> and shared the view that it looked like &#8220;<a href=\"http:\/\/www.tomstechblog.com\/post\/2008\/04\/Google-App-Engine-Free-and-still-barely-worth-it.aspx\">The World&#8217;s Worst Webhost<\/a>&#8220;.  My <a href=\"http:\/\/www.bluehost.com\/\">current webhost<\/a> lets me run ruby, perl, php <u>and<\/u> python with either mysql or postgres, so why would I want to limit myself to python and some proprietary, lock-in database. The answer is, of course, scale.<\/p>\n<p>And so here is the dilemma.  If you are developing a new web application from scratch what do you do if you think \/ hope that one day you will be wildly successful?  There is the flickr \/ facebook \/ myspace path i.e. use a single relational database till it breaks, then use master \/ slave and then shard (<a href=\"http:\/\/www.baselinemag.com\/c\/a\/Projects-Networks-and-Storage\/Inside-MySpacecom\/\">gory details for myspace<\/a>) and now there is the google app engine path i.e. build the application from the start in a way that is guaranteed to scale out with no herculean efforts.  <\/p>\n<p>This is not an easy choice.  The problem with the google path is that their datastore has <a href=\"http:\/\/code.google.com\/appengine\/articles\/cf1-text.html\">no joins, limited transaction support and some random query limitations<\/a>.  Now, I have never built an application with those limitations, but I would guess that it takes longer to build and requires a whole <a href=\"http:\/\/blog.labnotes.org\/2007\/09\/20\/read-consistency-dumb-databases-smart-services\/\">new way of thinking<\/a>.<\/p>\n<p>The google app engine path seems difficult to justify for a new app. It&#8217;s built on the premise that the app will be wildly successful and most web apps aren&#8217;t.  Justifying the additional upfront expense to investors \/ management won&#8217;t be easy and given that many big names have already successfully traversed the other path, it may be better to start by choosing one of the world&#8217;s better webhosters and only invest in scaling the db when the money starts rolling in.<\/p>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Assaf Arkin: if anything I wrote sounds vaguely familiar because you somehow managed to dumb your RDBMS into storing structured data in BLOBs, added versions and timestamps on all records, grappled with minimizing transactions and locks, denormalized data like there\u2019s no tomorrow, or relied too much on a message queue, then time to rethink. Are &hellip; <a href=\"https:\/\/robubu.com\/?p=35\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Scaling Databases and Google&#8217;s App Engine&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false},"version":2}},"categories":[1],"tags":[],"class_list":["post-35","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/robubu.com\/index.php?rest_route=\/wp\/v2\/posts\/35","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/robubu.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/robubu.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/robubu.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/robubu.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=35"}],"version-history":[{"count":0,"href":"https:\/\/robubu.com\/index.php?rest_route=\/wp\/v2\/posts\/35\/revisions"}],"wp:attachment":[{"href":"https:\/\/robubu.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=35"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/robubu.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=35"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/robubu.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=35"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}