<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Scott Yang's Playground &#187; architecture</title>
	<atom:link href="http://scott.yang.id.au/tag/architecture/feed/" rel="self" type="application/rss+xml" />
	<link>http://scott.yang.id.au</link>
	<description>Faith, Technology and Randomness in Life, According to Scott</description>
	<lastBuildDate>Thu, 09 Feb 2012 09:01:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Al3x on Twitter Architecture</title>
		<link>http://scott.yang.id.au/2008/05/al3x-on-twitter-architecture/</link>
		<comments>http://scott.yang.id.au/2008/05/al3x-on-twitter-architecture/#comments</comments>
		<pubDate>Fri, 23 May 2008 01:09:45 +0000</pubDate>
		<dc:creator>scotty</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[architecture]]></category>
		<category><![CDATA[Twitter]]></category>

		<guid isPermaLink="false">http://scott.yang.id.au/2008/05/al3x-on-twitter-architecture/</guid>
		<description><![CDATA[Alex Payne, a Twitter developer, talks about its architecture and scalability issue. Twitter is, fundamentally, a messaging system. Twitter was not architected as a messaging system, however. For expediency&#8217;s sake, Twitter was built with technologies and practises that are more appropriate to a content management system. Over the last year and a half we&#8217;ve tried [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.al3x.net/">Alex Payne</a>, a <a href="http://twitter.com/">Twitter</a> developer, <a href="http://dev.twitter.com/2008/05/twittering-about-architecture.html">talks about its architecture and scalability issue</a>.</p>
<blockquote><p>Twitter is, fundamentally, a messaging system. Twitter was not architected as a messaging system, however. For expediency&#8217;s sake, Twitter was built with technologies and practises that are more appropriate to a content management system. Over the last year and a half we&#8217;ve tried to make our system behave like a messaging system as much as possible, but that&#8217;s introduced a great deal of complexity and unpredictability.</p></blockquote>
<p><img src="http://scott.yang.id.au/file/images/twitter-downtime.jpg" width="300" height="178" alt="Twitter Downtime" class="floaty" style="padding:3px;border:#ccc solid 1px"/> The fundamental problem of the Twitter architecture is trying to massage a state-less request/response system that is most suitable for read-intensive applications, to a write-intensive message-based system. Basically &#8212; getting <a href="http://www.rubyonrails.org/">Ruby on Rails</a> to do what <a href="http://www.jabber.org/">Jabber/XMPP Server</a> was designed to do &#8212; something is not right! Twitter not being able to scale is not that they haven&#8217;t thrown in enough boxes, or they haven&#8217;t cached the right content in the right place, or they haven&#8217;t implemented a right cluster solution for the database. Not even because RoR is slow, in the way <a href="http://www.techcrunch.com/2008/05/22/twitter-at-scale-will-it-work/">Tech Crunch puts it</a>. It does not scale because it was not architectured to what it was supposed to do. A paradigm shift is required. Maybe they should have started with an Erlang backend in the beginning, like <a href="http://highscalability.com/new-facebook-chat-feature-scales-70-million-users-using-erlang">what Facebook did with their chat system</a>.</p>
<p>Re-architecture an existing system is never fun though. Not many can afford a second team doing a rewrite. Rewriting component by component is not really optimal, especially if the original design was not well componentised (for scalability&#8217;s sake, it&#8217;s often not!) At work we have also been talking about rewriting the backends (to increase scalability + server utilisation) and frontends (employ various RIA techniques), and it has been very <em>frustrating</em> when you lay it out &#8220;what needs to be done&#8221;, but management&#8217;s asking &#8220;can it be done bit by bit?&#8221; or &#8220;does it add any functionality?&#8221; (mind you that our SaaS product is maybe 500x more complicated than Twitter although requiring only 1/100000&#8242;s scalability). Yes. Frustrating.</p>
<p>Anyway. Good luck to Twitter because I really want to use it. Except it is not working right now. Message via Jabber is broken&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://scott.yang.id.au/2008/05/al3x-on-twitter-architecture/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

