{"id":101,"date":"2007-08-25T23:22:15","date_gmt":"2007-08-26T07:22:15","guid":{"rendered":"http:\/\/www.sauria.com\/blog\/2007\/08\/25\/scalability-concurrency\/"},"modified":"2020-04-13T10:29:33","modified_gmt":"2020-04-13T18:29:33","slug":"scalability-concurrency","status":"publish","type":"post","link":"https:\/\/www.sauria.com\/blog\/2007\/08\/25\/scalability-concurrency\/","title":{"rendered":"Scalability != concurrency"},"content":{"rendered":"<p>Sam Ruby is <a href=\"http:\/\/intertwingly.net\/blog\/2007\/08\/25\/Lean-Languages-and-Libraries\">writing<\/a> about Russell Beattie <a href=\"http:\/\/www.russellbeattie.com\/blog\/java-needs-an-overhaul\">writing<\/a> about Java and Erlang.<\/p>\n<p>Russell thinks Java needs an overhaul.  I think that Java has reached the point where technical, community, and business forces well exert pressure on the language to evolve in a uniformly bad manner.  <\/p>\n<p>Russell wrote:<\/p>\n<blockquote><p>The reason people are looking at Erlang is not because its beautiful syntax, great documentation, or up-to-date libraries. Trust me. It&#8217;s because the Erlang VM can run for long periods of time, scaling linearly across cores or processors filling the same niche that Java does right now on the server.<\/p><\/blockquote>\n<p>Actually, I am looking at Erlang as a solution for anywhere, (including the client) where concurrency will be an issue.   By the way, it is not VM&#8217;s that scale linearly, but computational problems.   And there are some problems which just can&#8217;t scale linearly, no matter what VM we put them on.<\/p>\n<p>Sam goes on to make the point which is the title of this post.<\/p>\n<blockquote><p>Next, to dispel a few myths.  Slashdot is written in Perl, seems to handle the load, and also seems to stay up.  While there are a number of BitTorrent implementations, the original and (to the best of my knowledge) the most pervasive version is written in Python.  Yahoo is a mix, but a good portion of it is written in PHP, with critical functions written in C.  Twitter is written in Ruby, had early scalability issues, but seems to be past them.  These are all examples of massively scalable applications.<\/p><\/blockquote>\n<p>Scalability is not the same thing as concurrency.   It is certainly possible to scale a program written in any language &#8211; that&#8217;s a given.    Especially when scaling = throwing more hardware at it.   But there&#8217;s got to be a better way of doing it.  Question is whether the better way is worth the price of admission.<\/p>\n<p>But as far as Erlang vs Java, the real kicker is here:<\/p>\n<blockquote><p>Unlike the CLR which was designed to be multi-language, and unlike the JVM which is in the process of being repurposed to be multi-language also, Erlang&#8217;s VM is designed from the ground up assuming that objects typically are immutable and serializable.<\/p><\/blockquote>\n<p>Which is what makes the situation with Java so bad.   Not only is the language bad, the VM is fatally flawed when it comes to actor style concurrency (which is why for all its niceties, Scala will suffer the same problems as Java).   There&#8217;s a real problem here &#8212; ask yourself why there is a market for <a href=\"http:\/\/www.azulsystems.com\/products\/compute_appliance.htm\">these things<\/a>, if all that is needed is to throw even more boxes at the problem.<\/p>\n<p>In the comments, Sam wrote;<\/p>\n<blockquote><p>The biggest problem I have with Erlang is clearly an addressable one: the documentation of the libraries, and the lack of good samples that can be quickly found by Google\/MSN-Live\/Yahoo!\/Ask searches.  And many of the libraries appear to be abandoned at 0.n versions.<\/p><\/blockquote>\n<p>This is actually 2 problems.  There&#8217;s the issue with the libraries, and there&#8217;s the issue with the community that did\/didn&#8217;t produce the libraries.   We don&#8217;t just need a technology, we need a community.  Hmm, Erlang <a href=\"http:\/\/labs.apache.org\/\">lab<\/a>, anyone?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Sam Ruby is writing about Russell Beattie writing about Java and Erlang. Russell thinks Java needs an overhaul. I think that Java has reached the point where technical, community, and business forces well exert pressure on the language to evolve in a uniformly bad manner. Russell wrote: The reason people are looking at Erlang is [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[26],"tags":[154,44],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/phUVc-1D","_links":{"self":[{"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/posts\/101"}],"collection":[{"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/comments?post=101"}],"version-history":[{"count":1,"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/posts\/101\/revisions"}],"predecessor-version":[{"id":598,"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/posts\/101\/revisions\/598"}],"wp:attachment":[{"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/media?parent=101"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/categories?post=101"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sauria.com\/blog\/wp-json\/wp\/v2\/tags?post=101"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}