<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:yt="http://gdata.youtube.com/schemas/2007" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">
   <channel>
      <title>Robert Fischer&amp;#39;s Blog Posts</title>
      <description>Pipes Output</description>
      <link>http://pipes.yahoo.com/pipes/pipe.info?_id=f17e49e7657a8bc40b557dc02ba6bd93</link>
      <pubDate>Tue, 16 Mar 2010 10:20:44 -0700</pubDate>
      <generator>http://pipes.yahoo.com/pipes/</generator>
      <atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/em-robert" /><feedburner:info uri="em-robert" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><geo:lat>36.087738</geo:lat><geo:long>-78.923139</geo:long><item>
         <title>Open Source Update: jQuery PeriodicalUpdater, TestingLabs, GPars, etc.</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/mN-h67ZnS3g/</link>
         <description>I've done a fair bit of fairly small open source updates recently.</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2353</guid>
         <pubDate>Fri, 12 Mar 2010 10:28:20 -0800</pubDate>
         <content:encoded><![CDATA[<p>I&#8217;ve done a fair bit of fairly small open source updates recently.</p>
<ul>
<li><code>jQuery PeriodicalUpdater</code>: The main function now returns a handle that can be used to call <code>stop()</code>, thereby ignoring any updates that may come back and preventing future updates from being sent.</li>
<li><code>TestingLabs</code>: I released TestingLabs 0.4 to work with Grails 1.2.0. Had a bug with versioning under Grails: <a rel="nofollow" target="_blank" href="http://jira.codehaus.org/browse/GRAILSPLUGINS-2023">More info on JIRA</a>.</li>
<li><code>Presentations</code>: I&#8217;m now storing the slides for my presentations on GitHub. They&#8217;re under a Creative Commons License.</li>
<li><code>ClosureBridge</code>: This is a tiny library (up on <a rel="nofollow" target="_blank" href="http://repo.smokejumperit.com">the repo.smokejumperit.com Maven repo</a>) that provides a link between Groovy&#8217;s Closures and Callable/Runnable/Java code.</li>
<li><code>Fun with GPars</code>: A small library where I was experimenting with GPars</li>
<li><code>GPars</code>: Submitted a fix and generally been discussing things with the GPars community (and by that, I mean Vacalv Pech)</li>
</ul>
<p>See <a rel="nofollow" target="_blank" href="https://github.com/RobertFischer">my GitHub page</a> for more info.</p>
<hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on March 12, 2010.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/os-update-march2010/#respond">http://enfranchisedmind.com/blog/posts/os-update-march2010/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/os-update-march2010/">http://enfranchisedmind.com/blog/posts/os-update-march2010/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (203.215.201.194) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/mN-h67ZnS3g" height="1" width="1"/>]]></content:encoded>
         <category>Open Source</category>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/os-update-march2010/</feedburner:origLink></item>
      <item>
         <title>Scala: Post-Functional, Post-Modern, or Just Perl++?</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/EHqRUjXQLmY/</link>
         <description>Protip to Scala people: If one of the fundamental stunts of a style is pervasive in all the code but yours, you're not in the same style of programming.</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2330</guid>
         <pubDate>Sat, 06 Mar 2010 19:30:54 -0800</pubDate>
         <content:encoded><![CDATA[<h3>Let&#8217;s start with some background.</h3>
<p><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/scala-not-functional/">I complained that Scala did not seem to be very functional to me</a>, but I didn&#8217;t really know how best to express what was fundamentally wrong with it. I did know that if <a rel="nofollow" target="_blank" href="http://www.artima.com/scalazine/articles/goals_of_scala.html">&#8220;functional languages have a fixed set of features&#8221; like Scala&#8217;s creator, Odersky, claims</a>, then it wasn&#8217;t simply &#8220;first-class functions in there, function literals, closures&#8221;, &#8220;types, generics, [and] pattern matching&#8221;. Scala has missed the functional boat in some basic way.</p>
<p>After a kerfuffle in the comments, <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/what-is-a-functional-programming-language/">Brian enlightened us all by telling us what is a functional programming language</a>. His explanation (while being a self-admitted generalization) is summarized as follows:<br />
<blockquote>So, what is it that differentiates the functional programming languages from all the other programming languages? It is simply this: the functional programming languages use, as their fundamental model of computation, the lambda calculus, while all the other programming languages use the Turing machine as their fundamental model of computation.</p></blockquote>
<p>Six months later, <a rel="nofollow" target="_blank" href="http://www.scala-lang.org/node/4960">Odersky responds with a very interesting post</a>, which actually agrees that Scala is not a functional language in Brian&#8217;s sense, but instead argues that any language is functional if it &#8220;makes programming centered around functions easy and natural&#8221;. He then runs through a list of features which is in common with functional languages, noting that Scala has them within handwave enough (more on that later). He ends wishing that people would &#8220;stop thinking of functional programming as a different, novel, or exotic way to code&#8221;. Even more, though, Scala is apparently &#8220;an early example of a new breed of postfunctional languages&#8221;.</p>
<h3>And that gets us to this blog post.</h3>
<p>First of all, Odersky is still missing the point. It&#8217;s not about whether you use <code>fold</code>, <code>map</code>, and <code>iter</code>, or whether you can write closures easily. It&#8217;s not even really about pure functions vs. side-effects. To code in a functional style is a fundamentally different way of thinking about problems: instead of thinking about problems as nouns that are doing things, functional programming views a problem as a series of transformations to the world which results in an answer. This is why functional programming is considered &#8220;a different, novel, or exotic way to code&#8221;: it <em>is</em> a different, novel, and (as of yet) exotic way to code. It&#8217;s as different, novel, and exotic from OO as OO was from procedural. It&#8217;s a different way of thinking about the entire issue. You can <a rel="nofollow" target="_blank" href="http://itmmetelko.com/blog/2008/02/23/functional-programming-immutable-objects-explained-irc-style/">check out this snippet of an IRC conversation from #ocaml</a> for more on that.</p>
<p>The paragon of this way of programming is <a rel="nofollow" target="_blank" href="http://buffered.io/2009/06/27/point-free-style-what-is-it-good-for/">point-free programming</a>, where you are quite literally building up a mega-function that describes how your program works, and then executing that one, single function when you run that program. If your language doesn&#8217;t lead people to re-discover point free programming at least in the small, then the language really isn&#8217;t taking function manipulation and functional language type conceptions seriously. And that&#8217;s the case with Scala: even Odersky admits that in Scala, &#8220;currying is more verbose and much less used than in other functional languages&#8221;. (Protip to Scala people: If one of the fundamental stunts of a style is pervasive in all the code but yours, you&#8217;re not in the same style of programming.)</p>
<p>What really gets me, though, is the claim that Scala is &#8220;an early example of a new breed of postfunctional languages&#8221;, because aside from the static typing, all the language features that Odersky trots out already exist in Perl. It&#8217;s hard to be a vanguard of a new breed of programming languages when there&#8217;s prior art <a rel="nofollow" target="_blank" href="http://history.perl.org/PerlTimeline.html#1980s">from the 1980s</a>.</p>
<p>Don&#8217;t believe me? <a rel="nofollow" target="_blank" href="http://www.amazon.com/exec/obidos/ASIN/1558607013/lovespiralsof-20">The existence of a book on the topic unconvincing</a>? Then let&#8217;s run the list of functional language features from Odersky.</p>
<ul>
<li>Functions as first class values: <em>check</em>. <div class="wp_syntax"><div class="code"><pre class="perl" style="font-family:monospace;"><span style="color:#000000;font-weight:bold;">sub</span> apply<span style="color:#009900;">&#40;</span><span style="color:#339933;">&amp;</span><span style="color:#0000ff;">$)</span> <span style="color:#009900;">&#123;</span> <span style="color:#666666;font-style:italic;"># Take a function as an argument no problem</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">0</span><span style="color:#009900;">&#93;</span><span style="color:#339933;">-&gt;</span><span style="color:#009900;">&#40;</span><span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">1</span><span style="color:#009900;">&#93;</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">;</span>
<span style="color:#009900;">&#125;</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">sub</span> times2<span style="color:#009900;">&#40;</span><span style="color:#0000ff;">$)</span> <span style="color:#009900;">&#123;</span> <span style="color:#666666;font-style:italic;"># Create a function to take</span> <span style="color:#000066;">print</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">0</span><span style="color:#009900;">&#93;</span><span style="color:#339933;">*</span><span style="color:#cc66cc;">2</span> <span style="color:#339933;">.</span> <span style="color:#ff0000;">"<span style="color:#000099;font-weight:bold;">&#92;n</span>"</span><span style="color:#339933;">;</span>
<span style="color:#009900;">&#125;</span>
&nbsp;
apply<span style="color:#009900;">&#40;</span><span style="color:#0000ff;">&#92;&amp;times2</span><span style="color:#339933;">,</span> <span style="color:#cc66cc;">3</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">;</span></pre></div></div> </li>
<li>Convenient closure syntax: <em>check</em> <div class="wp_syntax"><div class="code"><pre class="perl" style="font-family:monospace;"><span style="color:#b1b100;">my</span> <span style="color:#0000ff;">$x</span> <span style="color:#339933;">=</span> <span style="color:#cc66cc;">2</span><span style="color:#339933;">;</span>
apply <span style="color:#009900;">&#123;</span> <span style="color:#000066;">print</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">0</span><span style="color:#009900;">&#93;</span><span style="color:#0000ff;">*$x</span> <span style="color:#339933;">.</span> <span style="color:#ff0000;">"<span style="color:#000099;font-weight:bold;">&#92;n</span>"</span> <span style="color:#009900;">&#125;</span> <span style="color:#cc66cc;">3</span><span style="color:#339933;">;</span>
&nbsp;
<span style="color:#b1b100;">my</span> <span style="color:#0000ff;">$times_x</span> <span style="color:#339933;">=</span> <span style="color:#000000;font-weight:bold;">sub</span><span style="color:#009900;">&#40;</span><span style="color:#0000ff;">$)</span> <span style="color:#009900;">&#123;</span> <span style="color:#000066;">print</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">0</span><span style="color:#009900;">&#93;</span><span style="color:#0000ff;">*$x</span> <span style="color:#339933;">.</span> <span style="color:#ff0000;">"<span style="color:#000099;font-weight:bold;">&#92;n</span>"</span><span style="color:#339933;">;</span>
<span style="color:#009900;">&#125;</span><span style="color:#339933;">;</span>
<span style="color:#0000ff;">$times_x</span><span style="color:#339933;">-&gt;</span><span style="color:#009900;">&#40;</span><span style="color:#cc66cc;">3</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">;</span></pre></div></div> </li>
<li>List comprehensions: <em>check</em>. (See <a rel="nofollow" target="_blank" href="http://perldoc.perl.org/index-functions-by-cat.html#Functions-for-list-data">perlfunc on list data</a>.)
</li>
<li>&#8220;Curried&#8221; function definitions and applications: check-ish.<br />
Okay, so calling this a &#8220;check&#8221; on Scala is a bit of a reach (<a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/scala-not-functional/#currying">cite</a>, <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/scala-not-functional/#comment-35168">cite</a>, <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/scala-not-functional/#comment-35550">cite</a>, although <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/scala-not-functional/#comment-35231">note this</a>—<a rel="nofollow" target="_blank" href="http://www.codecommit.com/blog/scala/function-currying-in-scala">here</a> is a more sympathetic run-down on Scala currying). Ignoring the <code>foo(2,_:Int)</code> syntax for a moment, we can implement basically the same style of &#8220;&#8216;curried&#8217; function definitions&#8221; such as Scala&#8217;s <a rel="nofollow" target="_blank" href="http://www.scala-lang.org/docu/files/api/scala/List.html#foldLeft%28B%29">List#foldLeft</a>. <div class="wp_syntax"><div class="code"><pre class="perl" style="font-family:monospace;"><span style="color:#000000;font-weight:bold;">sub</span> add <span style="color:#009900;">&#123;</span> <span style="color:#b1b100;">my</span> <span style="color:#0000ff;">$x</span> <span style="color:#339933;">=</span> <span style="color:#000066;">shift</span><span style="color:#339933;">;</span> <span style="color:#000066;">return</span> <span style="color:#000000;font-weight:bold;">sub</span> <span style="color:#009900;">&#123;</span> <span style="color:#0000ff;">$x</span> <span style="color:#339933;">+</span> <span style="color:#000066;">shift</span> <span style="color:#009900;">&#125;</span><span style="color:#339933;">;</span>
<span style="color:#009900;">&#125;</span>
add<span style="color:#009900;">&#40;</span><span style="color:#cc66cc;">2</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">-&gt;</span><span style="color:#009900;">&#40;</span><span style="color:#cc66cc;">3</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">;</span> <span style="color:#666666;font-style:italic;"># Okay, so you do need an extra -&gt;</span></pre></div></div> <p>In the case of our <code>apply</code> function above (where we take a function as the first argument), it&#8217;s even easier.</p> <div class="wp_syntax"><div class="code"><pre class="perl" style="font-family:monospace;">apply <span style="color:#009900;">&#123;</span> <span style="color:#000066;">print</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">0</span><span style="color:#009900;">&#93;</span><span style="color:#0000ff;">*$x</span> <span style="color:#339933;">.</span> <span style="color:#ff0000;">"<span style="color:#000099;font-weight:bold;">&#92;n</span>"</span> <span style="color:#009900;">&#125;</span> <span style="color:#cc66cc;">8</span><span style="color:#339933;">;</span></pre></div></div> <p>Now, there isn&#8217;t really argument skipping (i.e.: <code>foo(_:Int,3)</code>) as a syntax feature, and there isn&#8217;t a built-in <code>curry</code> function, but if you want Scala&#8217;s <code>Function.curried</code> in perl, here it is:</p> <div class="wp_syntax"><div class="code"><pre class="perl" style="font-family:monospace;"><span style="color:#666666;font-style:italic;"># This code released under Creative Commons 0 and WTFPL.</span>
<span style="color:#000000;font-weight:bold;">sub</span> curry<span style="color:#009900;">&#40;</span><span style="color:#339933;">&amp;@</span><span style="color:#009900;">&#41;</span> <span style="color:#009900;">&#123;</span> <span style="color:#b1b100;">my</span><span style="color:#009900;">&#40;</span><span style="color:#0000ff;">$f</span><span style="color:#339933;">,</span><span style="color:#0000ff;">@args</span><span style="color:#009900;">&#41;</span> <span style="color:#339933;">=</span> <span style="color:#0000ff;">@_</span><span style="color:#339933;">;</span> <span style="color:#000066;">return</span> <span style="color:#000000;font-weight:bold;">sub</span> <span style="color:#009900;">&#123;</span> <span style="color:#0000ff;">$f</span><span style="color:#339933;">-&gt;</span><span style="color:#009900;">&#40;</span><span style="color:#0000ff;">@args</span><span style="color:#339933;">,</span> <span style="color:#0000ff;">@_</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">;</span> <span style="color:#009900;">&#125;</span><span style="color:#339933;">;</span>
<span style="color:#009900;">&#125;</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">sub</span> add<span style="color:#009900;">&#40;</span><span style="color:#0000ff;">$$</span><span style="color:#009900;">&#41;</span> <span style="color:#009900;">&#123;</span> <span style="color:#000066;">return</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">0</span><span style="color:#009900;">&#93;</span> <span style="color:#339933;">+</span> <span style="color:#0000ff;">$_</span><span style="color:#009900;">&#91;</span><span style="color:#cc66cc;">1</span><span style="color:#009900;">&#93;</span><span style="color:#339933;">;</span>
<span style="color:#009900;">&#125;</span>
&nbsp;
<span style="color:#b1b100;">my</span> <span style="color:#0000ff;">$curried</span> <span style="color:#339933;">=</span> curry<span style="color:#009900;">&#40;</span><span style="color:#0000ff;">&#92;&amp;add</span><span style="color:#339933;">,</span> <span style="color:#cc66cc;">2</span><span style="color:#009900;">&#41;</span><span style="color:#339933;">;</span> <span style="color:#000066;">print</span> <span style="color:#0000ff;">$curried</span><span style="color:#339933;">-&gt;</span><span style="color:#009900;">&#40;</span><span style="color:#cc66cc;">3</span><span style="color:#009900;">&#41;</span> <span style="color:#339933;">.</span> <span style="color:#ff0000;">"<span style="color:#000099;font-weight:bold;">&#92;n</span>"</span><span style="color:#339933;">;</span></pre></div></div> </li>
<li>Lazy evaluation: <em>check</em>. See <a rel="nofollow" target="_blank" href="http://search.cpan.org/~jesse/Scalar-Defer-0.23/lib/Scalar/Defer.pm">Scalar::Defer</a> for lazy val equivalents and <a rel="nofollow" target="_blank" href="http://search.cpan.org/~genie/Tie-LazyList-0.05/LazyList.pm">Tie::LazyList</a> for lazy seq equivalents. People generally use a <a rel="nofollow" target="_blank" href="http://www.perldesignpatterns.com/?LazyEvaluation">double-return approach</a> for generators (which I realize are different than lazy seqs and only kinda-sorta lazy).
</li>
<li>Pattern matching: <em>check</em> (okay, check-ish). See <a rel="nofollow" target="_blank" href="http://perldoc.perl.org/Switch.html">Switch</a>. The decomposition isn&#8217;t there, which is the biggest weakness. But the general cumbersomeness and lack of real algebraic data types hamstrings the coolest parts of pattern matching anyway, so I&#8217;m calling it a draw. (This should be read as a generous and sympathetic ruling for Scala: Cedric Beust, for instance, rails against pattern matching/case classes and says &#8220;<a rel="nofollow" target="_blank" href="http://beust.com/weblog2/archives/000490.html">it&#8217;s hard for me to see case classes as anything but a failure</a>&#8220;.)</li>
</ul>
<p>In addition, perl&#8217;s got a few features in its favor for functional programming, like more flexible arguments, <a rel="nofollow" target="_blank" href="http://en.wikipedia.org/wiki/Autovivification">autovificiation</a>, list/argument coercion, and dynamic symbol table mangling. Since perl also has OO capabilities, perl is <em>at least</em> as convincing a &#8220;post-functional language&#8221; as Scala. But there&#8217;s even more in common between the two than that.</p>
<p>Odersky&#8217;s &#8220;post-functional language&#8221; is really a subtype of <a rel="nofollow" target="_blank" href="http://www.wall.org/~larry/pm.html">Larry Wall&#8217;s &#8220;post-modern language&#8221;</a>: it&#8217;s an attempt to create a language that is a grab-bag of multiple paradigms. And when you do that, you&#8217;re just begging for the complaints that you hear leveled against both perl and Scala: it&#8217;s too complicated, its syntax is weird, it&#8217;s too magical, people write in entirely distinct subsets of the language, etc. (<a rel="nofollow" target="_blank" href="http://creativekarma.com/ee.php/weblog/comments/my_verdict_on_the_scala_language/">cite</a>, <a rel="nofollow" target="_blank" href="http://www.weiqigao.com/blog/2008/03/24/scala_still_uncomfortable_after_five_years.html">cite</a>, <a rel="nofollow" target="_blank" href="http://neopythonic.blogspot.com/2008/11/scala.html">cite</a>) Now, those who master the language (or master their favorite subset of it) love the <a rel="nofollow" target="_blank" href="http://en.wikipedia.org/wiki/There's_more_than_one_way_to_do_it">TIMTOWTDI</a> aspect. But it also means that the language is left as a jack-of-all-trades, master of none. Yes, Scala and perl integrate a lot of powerful tools from functional languages—but learning OCaml still blew my mind, despite knowing perl for years. As I started off saying, Scala is not a functional programming language. It is a statically typed object oriented language with closures.</p>
<p>Now, there is a sense in which Odersky is really onto something. The world of programming is forever transformed with closures and list comprehensions as being mandatory for new high-level languages, even if they&#8217;re otherwise object oriented. And software developers are going to need how to work with them effectively if they want to read code moving forward. Yes, after 20+ years, the rest of the programming world finally caught up to one of perl&#8217;s fundamental insights.</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37346">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://blog.barrkel.com/' class='url'>Barry Kelly</a> wrote: Functional programming optimizes for different things than OO does. That means for different problems, you want to take different approaches, depending on your level of familiarity with the problem domain and the solution strategies. And thus for a language that supports both paradigms, different people will often end up using different subsets of the language. But I don't think this is necessarily a damning criticism. Our problems are bigger and more compositional. We need languages that have the semantic richness to support different solution strategies. An example. There's an isomorphism between OO polymorphism / dynamic dispatch, and algebraic data types / pattern matching and destructuring. OO lets you add subclasses as late as dynamically at runtime. ADT lets you add functions freely, and such functions are more composable that they're dealing with well-defined quantities. More generally, OO is about defining loosely bound protocols, while FP is more about flexibly defining transformations over tightly defined structures. But if you want to write a solution that's natural for one paradigm in the other, you end up re-inventing and poorly reinventing the other paradigm. In a comment somewhere else out in the ether, I made an argument that getting FP to work as well as a dynamically typed late bound language like Ruby for fast-iterating web solutions that join together multiple independently developed and fast-iterating modules, you'd end up writing what amounted to a dynamic language just to avoid the brittleness that comes from the over-specification that naturally falls out of static typing. I will agree that e.g. currying is useful, as it decomposes the concept of functions of arbitrary arity into what amounts to a linked list of unary functions; and this is particularly handy for programming in a point-free style. But point-free mostly helps (I would assert) on problems where what you need to do is create an algorithm, where little helpers like fold, map, memoize etc. are your bread and butter. But not all problems are like that, not by a long shot.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37347">March 7, 2010</a>, Ittay wrote: "because aside from the static typing, all the language features that Odersky trots out already exist in Perl" That is a big 'aside'. You also forgot that Scala runs on the JVM and Perl not. Not to mention that I think it is common consensus that Perl code is very unreadable. So Scala is a language that combines some FP characteristics with OO, running on the JVM and with a readable (and scalable) syntax. That's a big win for me.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37348">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: I will freely grant that there's a lot to be gained by having some flexibility, but languages that end up trying to play in multiple sandboxes end up either doing one part badly (e.g. OCaml and OO, Scala and functional). The answer seems to be using multiple languages for different contexts, not trying to create the One True Language with all the features of the world in it. That's why when I encounter a programming problem, I will generally reach for perl, Groovy, or OCaml/F#: which one I go for depends on the nature of the problem. But I don't long for a day when there's a language that has all the features of perl, Groovy, and OCaml, because they're fundamentally incompatible takes on the process of programming. The strongly opinionated natures of these languages is precisely what makes them so good. Scala's lack of strong opinions is what's frustrating me. Well, that and having to explain to Java devs over and over again at No Fluff events that learning Scala does not mean learning to program in a functional style. I mean, you <em>can</em> code Scala in a functional style, but <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/this-is-your-brain-this-is-your-brain-on-ocaml/">I can code Java in a functional style</a>. And yes, it's a <em>bit</em> easier to code in a functional style in Scala, but learning Scala is no more learning functional programming than learning perl is learning functional programming.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37349">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: The "readable (and scalable) syntax" bit is a big assumption—at least to my ear, there's as much concern about the readability of Scala code as there is about perl code. And how much Scala's static typing really helps vs. how much it gets in the way is a matter of contention. But both of those are an aside. The purpose of this post was not to say that people should stop coding Scala and start coding perl: if you're still futzing around in Java-land, Scala (like Groovy and JRuby) is a productivity huge win that can leverage your existing infrastructure. Groovy's probably the semantically closest, JRuby's the conceptually cleanest, and Scala keeps the fetishized complexity and the BDSM aspects of Java. No, this wasn't a call to go back to perl. The purpose of this post is to show that the idea of merging closures with imperative isn't a new idea, and that Scala is no more a functional language than those languages (like perl) which merged the concepts beforehand.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37351">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.illegalargument.com' class='url'>Richard Vowles</a> wrote: I've been saying this for 6 months at least now - Scala and Perl have way more in common than Scala has in common with any other language. Including a tendency towards unreadability.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37352">March 7, 2010</a>, Marc wrote: "It’s as different, novel, and exotic from OO as OO was from imperative." OO is as imperative, if not more so, than C. I assume you meant procedural? Also, there is nothing new in programming languages, period. Everything you see in "new" languages was figured out at least 20 years ago. So, all language designers are just mixing and matching as they see fit. So it's unfair to single out Scala in this regard. While you're at it, go after Groovy, Clojure, Boo, F#, etc.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37353">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.cirrusmachina.com/' class='url'>Nick Bauman</a> wrote: I find the description "combines some FP characteristics with OO" problematic when discussing hybrid Functional / OO languages. The more I use one of my favorites of these languages, Python, the more I find the OO aspects receding into the background and the functional ones coming to the fore. It seems to me that <b>Functional is OO "done right"</b> where when I do use OO in them, it's not as heavyweight and seems more natural. I think the key is that in most traditional OO languages the concept of what a type is tends to be much narrower. Can you confirm this in your experience?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37354">March 7, 2010</a>, Thomas Heywood wrote: Robert, I admire your ability to "professionally blog." You delivered no useful content, but you did it with inspiring attention to page hits and comment controversy. Yes, Scala is a multiparadigm language. Yes, Perl is one too. Yes, they both share features from Common Lisp. That's not really worth my or your time. But you cleverly used the confrontational tone to make the blatant non-issue into a controversial <i>issue</i>. You cleverly used Blogosphere's beloved "Scala" and "Perl" tags in a <i>single</i> article. You nagged about a minor syntax issue like it was life-or-death as only a true master-of-functional-programming-who-blogs-more-than-he-actually-programs can. Bob, you're my hero - a true <i>Dilbert's</i> Wally in flesh. A guy without any real code to show - but who "realigns the tone of existing projects" and whose "technical leadership focuses on pragmatic communication" like there's no tomorrow. Wally - sorry, Robert - do you think you could write some posts on how to professionally sell bull and call it "technical accomplishments?" Many of us CompSci majors would like to get in on this money for nothing scheme. Unless, of course, you're not comfortable writing about things you actually do know a little about.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37355">March 7, 2010</a>, Nilanjan Raychaudhuri wrote: Well I believe it is possible to write unreadable code in any language and I am not sure blaming any programming language for that is a good idea.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37356">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.codecommit.com/blog' class='url'>Daniel Spiewak</a> wrote: Throwing out static typing fundamentally changes what Scala has to offer. In a sense, I agree with you that if we completely threw out Scala's type system (and <i>all</i> that it entails), then we would end up with a language which improves very little (if at all) over languages like Perl or Ruby. However, that first step is a doozy and not really fair. Consider a snippet like this: <pre lang="scala">"123".to[Int] // =&gt; 123
".+".to[Regexp] // =&gt; /.+/
true.to[Regexp] // compile error!</pre> There's a lot of magic going on here, all of which is made possible by the static type system. In fact, while this sort of thing is *possible* in a dynamic language with open classes (like Ruby), the implementation will be ugly, unscoped, brittle and difficult to extend. In Scala, the implementation looks something like this: <pre lang="scala">trait Converter[-A, +B] { def apply(a: A): B
} implicit object StringToInt extends Converter[String, Int] { def apply(str: String) = str.toInt
} implicit object StringToRegexp extends Converter[String, Regexp] { def apply(str: String) = Regexp(str)
} implicit def toSyntax[A](a: A)= new { def to[B](implicit conv: Converter[A, B]) = conv(a)
}</pre> This is taking advantage of a feature which Scala inherits from Haskell called <i>typeclasses</i>. This is an feature which is inherently tied to static typing and is often very difficult to emulate in dynamic, so-called "more flexible" languages. The real magic of this is two-fold. First, it's scoped, and so we actually have to import these members before they start messing with our objects. It's hard to over-state how important this is to keeping such extensions from devolving into intractable monkey-patching. Second, it's extremely extensible. What if we want to add another conversion from Foo to Bar? Just define it ourselves as an implicit value in scope! Or, if we <i>don't</i> want the implicit syntax, we can always specify the conversion explicitly: <pre lang="scala">// off in *our* code, separate from the converter lib
implicit object StringToBool extends Converter[String, Boolean] { def apply(str: String) = str.toBoolean
} "true".to[Boolean] // =&gt; true
"false".to(StringToBool) // =&gt; false</pre> I'm not even going to try to imagine how to do this sort of thing in Perl. Even in Ruby, which usually makes monkey-patching quite simple, the implementation still ends up extremely nasty: <pre lang="ruby">class Object def to(target) case target when :fixnum if self.class == String self.to_i else raise "Unknown conversion: String -&gt; :fixnum" end # ... end end
end</pre> ...and, you get the picture. You could probably do this in a nicer way, but it would still end up being fragile, unscoped and virtually impossible to extend. <i>This</i> is what you're throwing away when you discard the type system, not some unreliable correctness "guarantee". And if I can throw together an example like this in a blog comment in just a few lines of Scala, imagine what can be done in a non-trivial system with real requirements. The type system is an intrinsic part of Scala's power and expresivity. Remove it and you're not even looking at the same language.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37357">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.codecommit.com/blog' class='url'>Daniel Spiewak</a> wrote: While currying and point-free aren't as syntactically clean as they could be in Scala, they are certainly still used (I use those features all the time). Does this make Scala less "functional" than Haskell or ML? Yeah, probably (I've made that argument in the past). Does it mean that Scala is no more functional than Perl? Absolutely not. Theoretically speaking, currying is possible in <i>any</i> language which supports closures (alblue, if you're reading, yes I do mean "closure" and not "lambda"). You can even define a curry function in C++, though the obfuscated template mess it entails makes it nigh unreadable. Lambdas ("closures" if you will) and function values do not a functional language make. C has function values, and I don't think anyone who understands the debate will argue that it is "functional". Ruby has function values <i>and</i> lambdas, but they are fundamentally different constructs and produce different values (just like in Perl). Again, not a functional language (though you can use many patterns which find their roots in FP, like <code>map</code> and <code>fold</code>). My point is this: you can't go out of your way to link FP to point-free and lambda calculus and then turn right around and claim that Perl and Scala are in the same league. Scala's unified functions and function values alone should be sufficient to overturn that one.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37358">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Yes, I meant procedural.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37359">March 7, 2010</a>, Martin wrote: You really can't claim "perl has had _____ since the 80's" and then point to books about Perl 5. Perl 25 years ago is *very* different than it is now. Your point that Scala and perl are similar is well taken, but I'm not totally clear why this is bad for Scala or Perl. The way Perl 6 is going towards a virtual machine, I wouldn't be surprised to see Perl and Scala and Java running together on a JVM sometime soon.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37360">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: I'm not saying it's bad for either Scala or perl to be similar to each other — on the point of similarity, I'm simply saying that in the ways Odersky argues Scala is "functional", perl is just as functional, and so I'm still unconvinced that Scala deserves to be called a "functional language". You don't hear people listing off the functional languages like: "Haskell, OCaml, perl, Lisp...". So to hear people say "Haskell, OCaml, Scala, Clojure" just gets my goat. I'm also saying that on the point of similarity, it shouldn't be a surprise that we're getting similar unreadability/complexity complaints about Scala as we got about perl, since they are so similar. I heard something about perl getting onto the JVM for AppEngine, but can't find additional info on it.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37361">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: In what ways do Scala's unififed functions and function values outperform perl?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37362">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Note the point I'm arguing: I'm arguing that Scala is no more a functional language than perl is. Functional languages can be dynamic (e.g. Clojure), so static vs. dynamic typing is irrelevant to the point I'm trying to make.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37363">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: You've earned a special spot in my heart: this is my new favorite flame of all time. I mean, the fact that you say I don't have "any real code to show" just goes to show that you're not paying attention, because you've somehow managed to miss my long trail of open source projects. And you kinda missed the boat on the entire fundamental question: "Is Scala a functional programming language?" But still, the Dilbert references, the accidentally-on-purpose "slip of the keyboard", and the general long-suffering tone is really nicely done. A+</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37364">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Oh, and you're fair on the dating thing. It's hyperbolic to conflate Perl 1 with Perl 5, although I honestly have no idea how far back I can go in perl and still have my code samples work. If you find out, let me know.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37365">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Brian Hurt, the co-blogger here on EnfranchisedMind, is theoretically working on a post about how OO is fundamentally broken. I'll leave that to him. My experience has been that many of the Gang of Four design patterns just aren't relevant anymore, and inheritance is something I'm extremely reluctant to use and much more aware of its difficulties. I'm not sure exactly what it would mean to say that "the concept of what a type is tends to be much narrower", but I certainly have a much thinner type hierarchies in the world of functional programming.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37366">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Oh, not to mention the cite of enterprise-ese from SmokejumperIT.com. I mean, that's some real attention to detail for the zingers. In all seriousness, this is my favorite flame of me of all time. Thanks!</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37367">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.naildrivin5.com/blog' class='url'>Dave</a> wrote: FWIW, I really dug this post. As to the topic at hand, I'm not even sure what point there is to saying Scala is or isn't "functional". The only real purpose seems to be to make it easy to show how awesome Haskell is by point out Scala's perceived shortcomings as a functional language. For my money, Scala is simply "Java: The Next Generation". A general-purpose, statically-typed, object-oriented language that has broad applicability to many problem domains. Arguing "what is functional" might be a fun exercise, but it's not really going to lead us anywhere; look at most n-tier Java applications: to say they are object oriented would be a vast overstatement. Java is object-oriented in that it's main means of organizing code are around classes and objects (which is exactly the same as in Scala), but most systems still end up using OO only when it helps, and throwing it for imperative/procedural stuff when it makes sense to do so. I would be willing to bet that Scala will be much the same way; the code <b>inside</b> our classes might be much more functional (simply because its' simply worth-it to do in Scala, whereas it's not terribly so in Java), but I don't see it ushering in some functional utopia (LISP has had, oh, I don't know, <i>the entire history of the field of computer science</i> to usher this in and largely failed [no offense to LISP]). Scala is an escape route from Java's cruftiness without having to bend your mind or prejudices <b>too</b> much. Much as Java was to C++.
</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37368">March 7, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.kaleidic.com' class='url'>Tracy Harms</a> wrote: The most interesting sentence in your post, to me, was this: <em>If your language doesn’t lead people to re-discover point free programming at least in the small, then the language really isn’t taking function manipulation and functional language type conceptions seriously.</em> This has me wondering, though, about your agreement with Brian that the key quality is reliance on lambda calculus as the model of computation. Not that I'm convinced we need a "key quality." It just looks to me that the range of languages you have in mind would not be identified through this criterion.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37369">March 8, 2010</a>, joe poki wrote: what's up with these groovy people nowadays? groovy++ is 10 trillion times faster than scala actors, now this piece. your rant could be summarized like I Do Not Like Scala. Look, I get that. But I must say it's funny that you use this patronizing tone with Odersky as he was a n00b who has no idea about languages and then once you get a trollish comment, you go on and post it everywhere: OMG somebody was responding to my trollish post in a trollish manner, what a surprise? as for your post:
just because a language can be used in a certain way (or certain language toolsets can be simulated in that language) that does not mean that the users will find that specific style idiomatic. What matters is the style you will meet the most while reading or writing code in that specific language (hack, even java has various functional libraries: lambdaj, functionaljava etc. but how many people would consider code written with these library java-like?). When people say that scala is "kinda functional", what they really mean is that the language is nudging you into that direction (preference for pattern matching, option type, final variables, map, foreach,closures, partial functions etc.). And this nudging towards the functional style is what makes scala "postfunctional". (other features responsible for the "scala feel" but not directly related to the functional thing: static typing w/ type inference, a powerful type system, xml literals, implicit converions, case classes, mixins + various actor libs etc.)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37370">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: My issue isn't with people saying Scala is "kinda functional". It's saying it's a "functional language". I've heard people say they want to learn Scala b/c then they'll know functional programming, and that's just wrong. Worse, I've heard people write off functional programming because they didn't like Scala. This means that the misconception that Scala is a functional language is hurting <em>real</em> functional language adoption and hindering people's advancement as software developers by making them think they know functional when they don't. So I'm trying to reinforce the barrier between real functional languages and languages with closures. I'm not particularly knocking Odersky here: what he's done with Scala is pretty impressive. But he's clinging to a title that Scala doesn't deserve. While I appreciate the move with "postfunctional", I'd be a big fan if it also meant he'd give up "functional" — but he's just taking both titles on. In so doing, he's diluting what we mean by a "functional language", and that's just not helpful to anyone involved. The evidence does seem to be that Odersky doesn't really know functional languages. Or, if he does know them, he knows them academically or intellectually, and doesn't really grok them. But you can't be an expert on everything, and I get that. This whole conversation is really kind of sad. There's such an extreme dichotomy here: the assumption seems to be that if you criticize a language, you must hate it. I don't hate Scala: Scala is what Java should be. It's finally a competitor to C# on the JVM — the advanced capabilities of C# have been downright embarrassing for a long time, and Scala evens the playing field. I'm just criticizing the way we talk about this language, and providing counter-evidence to some of the claims made about it.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37371">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Which languages do you see as missing one of the two qualities?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37372">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: As <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37370">I will say below</a>, my issue is mainly one of vocabulary and pedagogy, because I'm frustrated with the murky waters that such marketing-speak has created.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37374">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: <b>PS:</b> From someone who has been there <i>(remember: I'm a static typing fan, too)</i>: If you want to debate static typing usefulness vs. dynamic typing usefulness, don't argue that it's hard to implement type safety in a dynamically typed language. It doesn't win you any points with the dynamic language crowd, because they've already accepted they don't need it.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37376">March 8, 2010</a>, Peter Lewerin wrote: Daedalus and his son Icarus were imprisoned by King Minos, and made themselves wings out of wax and feathers to escape. Before they took off from the island, Daedalus warned his son not to fly too close to the sun. The sensation of flying made Icarus forget the warning and he soared higher and higher. Eventually the wax melted and he fell into the sea. A programmer can escape the prison of procedural programming using functional programming, but going for the purest form of FP isn't really a sustainable goal. Most likely, these wonktional programmers will melt their wings by straying too close to the realm of mathematics and plunge to their deaths.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37377">March 8, 2010</a>, Thomas Heywood wrote: <cite>And you kinda missed the boat on the entire fundamental question: “Is Scala a functional programming language?"</cite> Scala is a multiparadigm language that supports procedural, functional and object-oriented programming. We've had that since 1950s and Lisp. Now, what was the fundamental question again?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37378">March 8, 2010</a>, Thomas Heywood wrote: (Mea culpa: we've only really had it supplied with the language since 70s, when Lisp machines took off. Still, a blatant fact is blatant, no matter how much you blog it into shape.)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37379">March 8, 2010</a>, Vassil Dichev wrote: Robert, if you like Perl, that's nothing to be ashamed of :-) Seriously, I think your article is thought-provoking, if a little controversial. Still, there are several things I disagree with. First of all, I have interpreted Odersky's article in the spirit of: "OK, I don't insist on calling Scala a functional language". One important piece you didn't mention was immutable data structures. Perl doesn't scale very favorably here. Was this on purpose? I find it important not just what a language *can* do, but also what it *cannot* (easily) do. Mutation and scoping are some of the things Scala restricts rather successfully. I also don't find how the fact that Perl has flexible arguments, autovivificiation, list/argument coercion, and dynamic symbol table mangling makes it more functional. Does Haskell have these? Do you consider Haskell functional? Then I also don't see many people argue that Java is object-oriented. By the same reasoning, it's not- it certainly has types that are not objects, and you can certainly write in a procedural style in Java (unfortunately some people really do). Also, I don't see you arguing that OCaml is not object-oriented, because it's also considered a multi-paradigm language. I see that in one of your comments you agree that OO is poor in OCaml, which is fair enough, but I think some OCaml users wouldn't agree with you on this count either. I most emphatically agree that if you "know" how to write working Scala code, this doesn't mean you know all about functional programming. But I disagree that this harms "real" (read purer) functional languages any more than Java harms "real" object-oriented languages (whatever they are). In the end, I'm also fine with the definition of "statically typed object oriented language with closures".</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37380">March 8, 2010</a>, Vassil Dichev wrote: I've just read some of the blog posts you've linked to, and it's quite telling that <a rel="nofollow" target="_blank" href="http://creativekarma.com/ee.php/weblog/comments/my_verdict_on_the_scala_language/">two</a> of <a rel="nofollow" target="_blank" href="http://www.weiqigao.com/blog/2008/03/24/scala_still_uncomfortable_after_five_years.html">them</a> complain that Scala is <em>too</em> functional, while you complain that it's not functional <em>enough</em>. I think this is the problem with Scala: you can't appease everybody without any mental effort on their part to get used to the new style of programming. And I think the same can be said of OCaml. I also think OCaml would be a wonderful language to learn (and I might try it soon).</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37382">March 8, 2010</a>, Paul Kaletta wrote: All of your examples should work with any version of Perl 5, which came out in 1994.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37384">March 8, 2010</a>, Martin Odersky wrote: Robert: Your blog and even more so your comments make it sound as if I have no clue about what functional programming is. So, it must be because of a series of freak accidents that I organized ICFP, am a member of the IFIP working group on functional programming and am a member of the editorial board of the Journal of Functional Programming. And I even published quite a bit on lambda calculus, too :-). Seriously, I stand completely by my article on postfunctional programming. I believe your post here has added nothing of substance to the discussion. http://www.scala-lang.org/node/4960</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37386">March 8, 2010</a>, joe poki wrote: if you cite every single well-known post that dismisses scala one way or another and you go on and say "it’s too complicated, its syntax is weird, it’s too magical, people write in entirely distinct subsets of the language", then people will rightly assume you do not like scala, I do not get it why you are surprised (notice, I did not say you hate it, just that you dislike it). see, the patronizing stuff again "Odersky doesn’t really know functional languages". As I tried to point out: what matters is how a language is used and what's considered idiomatic and in that sense scala definitely has some functional feel to it (and no, it's not just about closures or foreach, but preference for pattern matching, option types, final variables, map, foreach,closures, partial functions etc. etc.).</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37387">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.kaleidic.com' class='url'>Tracy Harms</a> wrote: To the best of my knowledge, Factor, Joy, FL, and J are languages that favor anonymous arguments (and/or emphasize composition of functions) while lacking reliance on lambda expressions.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37388">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: If you're up for not calling Scala a "functional programming language", tell Odersky.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37389">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: It's not patronizing to say someone doesn't know something, or to disagree with the way someone is using language. That's just not what patronizing speech is. It'd be patronizing if I started explaining to Odersky what closures are and how they're supposed to work, or <a rel="nofollow" target="_blank" href="http://tinyurl.com/yk9nas8">if I sent you off to look at this link</a>. <em>That</em> would be patronizing.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37390">March 8, 2010</a>, Thomas Heywood wrote: <cite>Your blog and even more so your comments make it sound as if I have no clue about what functional programming is.</cite> Martin, hate to break it to you, but all you ever did was bring effective functional programming to a mainstream platform for the benefit of industry and academia. Call me back when you write a wrapper library or two, learn the persistence API of a web framework, or <cite>realign the tone of existing projects.</cite></li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37391">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: That's cool that you're so involved. Ultimately, though, our problem is boiling down to one of language. If Scala and perl are functional languages, how do we differentiate them from languages like Haskell, OCaml, and Lisp, where the fundamental way of tackling problems is different? I'd like to use the term "functional programming language" for the latter, and I'm more than happy to stick to "postfunctional programming language" or "multi-paradigm programming language" for the former. But that means we stop calling Scala a functional programming language, as most of the commenters here on the post already have. Deal?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37392">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Yeah, that's the general issue with these multiparadigm languages like Scala and perl. If OCaml narrowly avoided that fate (and I think it has), it was by completely subjugating the OO aspect to the functional aspect, and not really using the OO aspect much.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37393">March 8, 2010</a>, joe poki wrote: If you think saying somebody does not know squat about a subject while that person is supposed to be some sort of an expert on the topic is not condescending, then I do not know what is. By the way, it seems I was not alone, see Odersky's comment above.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37394">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: The immutability is a good point, and it's an area where Scala certainly pulls ahead. Actually, the Ruby (and, to a lesser extent, C#) people regularly say that Java isn't really OO, because a lot of things in Java weren't either objects or messages. I think Ruby inherited that criticism from the old SmallTalk people. And I'll happily argue that OCaml isn't object oriented: while it <em>has</em> objects, it's certainly not oriented towards them. What harms functional programming languages is when Java people learn Scala and then think they know functional programming languages. Or, worse, when they decide they don't like Scala and then conclude they don't like functional programming. This happens <em>a lot</em> because Scala was lauded as a functional programming language on the JVM which was comfortable for Java people. It's the murkiness in the water that's the issue.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37395">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.codecommit.com/blog' class='url'>Daniel Spiewak</a> wrote: In Perl, functions and lambdas are fundamentally different. If nothing else, this can be seen by the different invocation syntax. You can convert between functions and lambdas (just like in Ruby and Groovy), but they are very different constructs as far as the language is concerned. To me, one of the essentials of a functional language is that functions are merely lambdas which have been assigned to a named value. OCaml and Haskell encourage this notion with their syntax for function declaration (in fact, Haskell's function decl syntax is <i>exactly</i> the same as its value decl syntax). Perl doesn't even come close to meeting this qualification. Scala does <i>substantially</i> better, though I'll admit that it does have its gotchas (methods are sometimes tricky).</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37396">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: While that's a bit hardcore of a comparison (and somewhat damning on people's ability to learn), I definitely agree with your point. And Scala's great in this regard—as I said a number of times, I think Scala is where Java should be if Java's growth hadn't been stunted. If you look at how C# has evolved, Scala's basically right in line with that kind of development. And so a Java developer learning Scala in order to push their way of thinking about types and functions is a great move.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37397">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: True — I'm oversimplifying the world into imperative and functional. There are other paradigms out there (e.g. Factor's stack-based approach) which also can lead to point free programming.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37398">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Do they work before that? (Or, rather, would they work before that if I dumped the prototypes?)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37399">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: True: there are conversions that need to be made between functions and lambdas in perl. This suggests for Scala (as a multiparadigm language) having a somewhat stronger functional aspect than perl, but it still doesn't make it a functional programming language <i>a la</i> OCaml and Haskell.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37400">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://aliciaweller.com/' class='url'>Alicia</a> wrote: Wouldn't it be awesome if you really could make money writing b.s.? People won't even donate a dollar towards valuable open source projects...the suggestion that you could make money for being good at b.s. is hilarious.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37401">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Amen.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37402">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: True enough. I'm just trying to wrap my head around how Odersky can really grok functional programming and then assert that it's simply bolt-on features of a language. The difference between Haskell and Java is not simply one of syntactic sugar. Claiming he's mistaken about how FP works is actually a generous take—claiming he's clinging to the FP title for Scala for some ulterior reason when he should know better is much less generous. I was trying to give him the benefit of the doubt.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37403">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://james-iry.blogspot.com' class='url'>James Iry</a> wrote: Robert Fischer Finally Admits That Scala Is Functional (http://james-iry.blogspot.com/2010/03/robert-fischer-finally-admits-that.html)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37404">March 8, 2010</a>, Martin Odersky wrote: Robert, please, read my post again: http://www.scala-lang.org/node/4960 Nowhere did I define functional programming exclusively by a list of features. Instead I had as my central definition: "A functional language makes programming centered around functions easy and natural." A good test of this would be: is it common to write functional programs in the language in question? It's usually far easier to tell whether a program is functional than whether a programming language is functional. By that standard Scala is clearly functional; many of the classes and modules written in it are purely functional and every cool idea from Haskell seems to be implemented sooner or later in Scala (not that we don't invent some cool ideas of our own as well). I don't know Perl well enough to be able to tell whether there are many functional programs written in it, and whether the expression of such programs is easy and natural. Thanks anyway for giving me the benefit of the doubt that it's just misguidedness and not evilness that makes me insist on my ways.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37405">March 8, 2010</a>, bse wrote: Well, at least you admit you're writing about "religious issues", where arguments are replaced by belief. So by definition I can't argue with your expression of belief. However I don't have to agree with you.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37407">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: How do you account for this quote? <blockquote>The first thing we cared about was to have as clean an integration of functional and object-oriented programming as possible. We wanted to have first-class functions in there, function literals, closures. We also wanted to have the other attributes of functional programming, such as types, generics, pattern matching. And we wanted to integrate the functional and object-oriented parts in a cleaner way than what we were able to achieve before with the Pizza language. That was something we deeply cared about from the start. Later on, we discovered that this was actually very easy, because functional languages have a fixed set of features. They had been well researched and well proven, so the question was only how to best integrate that in object-oriented programming.</blockquote> <a rel="nofollow" target="_blank" href="http://www.artima.com/scalazine/articles/goals_of_scala.html">The Goals of Scala's Design</a></li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37408">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Ugh. I need to turn down the maximum comment nesting. It's getting out of control, and the box is getting REALLY skinny.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37409">March 8, 2010</a>, Martin Odersky wrote: Classical fallacy: I said: functional languages have a well-identified, fixed set of features. So being a functional language implies having that fixed set of features (or rather, some part of it because I was talking about the union of all functional languages). You think I said: having that fixed set of features implies being a functional language. But I never said that. Besides, that quote is not from the article I referred to. When I said "nowhere" I meant nowhere in that article, and I think that was clear from the context.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37410">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Okay, sure I'm taking your quotes from both your post on post-functional languages and another one on the design decisions behind Scala. Sorry if I overgeneralized your "nowhere". I read that quote as saying, "I went out to implement a functional language. This was easy, because it turns out implementing a functional language means implementing a fixed set of features." If that's not what you meant, what did you mean? I'm uncomfortable with your broad definition because it leads to confusion. Scala's extreme flexibility is exactly why I'm so resistant to labeling it a functional programming language — people learn the subset of Scala closest to Java and then think they know functional programming. I'm really, really tired of explaining to people that functional programming is more than list comprehensions. BTW, I want to say it straight to you, since I think things can get lost and there are some misconceptions floating around. I really do appreciate all you've done on the JVM languages—especially proving to folks who only know Java that there's more to static typing than Java's conception of it. And for all my pedantic resistance to calling Scala a functional language, it is one of my go-to languages for heavy lifting on the JVM. (My own experiments in programming language development have Scala cores.)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37412">March 8, 2010</a>, Martin Odersky wrote: Adding functional language constructs was relatively easy, because they are well understood. Making Scala an organic whole was hard. We can disagree whether this succeeded or not. The other question is, should a functional language force you to program in a functional style? Scala clearly does not, that's why I prefer to call it postfunctional. I understand your uneasiness that some people might take this as an excuse never to get into real FP at all.
Where we might differ is that I believe that in the long run Scala programmers will recognize the benefits of the functional programming style even if it is not forced down on them.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37414">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: I'd say that if a language doesn't force you to program in a functional style (or at least <em>strongly</em> encourage you that way), I'd consider it suspect as being a functional programming language at all. But I'm running on the stricter definition, as we've established. I hope that your sense of the future is true, and that the functional programming style becomes more widely adopted by way of Scala. And maybe being on the inside of Scala adoption, you're seeing that. Sitting here on the outside, though, I've seen the contrary, which is why I'm such a stick in the mud. Well, that and I'm preternaturally disposed towards being a stick in the mud.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37415">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/bhurt-aw/' class='url'>Brian Hurt</a> wrote: Let me turn that question around: should object oriented languages impose an object oriented approach? There is a value to learning, and really using, a paradigm. Is that limit you just hit a limit of the paradigm, or just a limit of your understanding of the paradigm? Until you expand your understanding, you don't really know- and the siren call of multi-paradigm languages is that they allow you to not expand your understanding by ditching the new paradigm early and often. There is another comparison (one you'll like even less) to another multi-paradigm language- C++. The reason C++ "won" was because it was multi-paradigm (procedural and OO), allowing people who didn't really understand OO to program in it. The reason C++ "lost" was because it was a multi-paradigm language, forcing people to deal with the old paradigm whether it was valuable to or not. The history of popular programming languages 1992-2007 was basically one of going ever less multi-paradigm and ever more pure OO. In other words, is Scala "post-functional" in the same sense that C++ is "post-Object-Oriented"?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37416">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://gabrielsw.blogspot.com' class='url'>Gabriel C.</a> wrote: If we're talking about how to LEARN functional programming, I totally agree that Scala is not the best choice (neither OCaml... the O part is there, lurking in the back...). I would recommend a pure functional lazily evaluated language (i.e. Haskell). My experience was the opposite of Robert's fears: I started learning FP with Scala (limiting myself to the functional subset of it) and then moved to learn Haskell (and I try to pick up as much as OCaml as I can on the way), but I guess I'm just weird: I've learned OO in C++ :)
But somewhat I agree in the comparison: C++ is to C as Scala is to Java</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37418">March 9, 2010</a>, joe poki wrote: Robert, I was actually talking about this kind of strong encouragement in my previous post when I said that scala was nudging you towards FP.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37419">March 9, 2010</a>, Martin Odersky wrote: If Scala had taken all of Java and then added FP to it, a comparison with C++ might have merit. But as it stands Scala
has thrown out or generalized a lot of Java's more crufty features. Where C++ is clearly much more complicated than C, the situation between Scala and Java is more balanced. Scala's syntax is a probably a bit simpler than Java's but its types are richer and more powerful. So you can say that Scala shares C++'s motivation -- take a well established programming style and let it branch out into a new paradigm. But it shares neither its approach (to be an almost strict superset of a base language) nor its overwhelming complexity.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37420">March 9, 2010</a>, <a rel="nofollow" target="_blank" href='http://blog.juma.me.uk' class='url'>Ismael Juma</a> wrote: Hey Robert, I found the following in your LinkedIn page: "Robert Fischer is a multi-language open source developer currently specializing in Groovy in Grails. In the past, his specialties have been in Perl, Java, Ruby, and OCaml. In the future, his specialty will probably be F# or (preferably) a functional JVM language like Scala or Clojure." What, did you just call Scala a functional language?! Ismael</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37421">March 9, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Busted! Really, that's exactly what I've been discussing with Martin O.—if you know functional programming already, you can do functional programming in Scala. And if you're on the JVM, like static typing, and want to do functional programming, you really don't have a better option. BTW, in Scala, I'm still struggling a bit to do functional programming in a way that's particularly friendly to Scala's approach — algebraic data types and function manipulation <i>a la</i> curry/flip are standard stunts for me, and I feel like I'm swimming upstream when I try those in Scala. I really should look more into some open source projects—anyone have one in Scala that's particularly functional? (In any case, I should update that since I'm now an .Net/F# developer.)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37422">March 9, 2010</a>, joe poki wrote: that is hilarious!</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37423">March 9, 2010</a>, peter pnin wrote: Robert, are you under the employ of Flying Frog Consultancy, perchance? There is a certain Harropity, if you will, to your blog post.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37425">March 9, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/candide/' class='url'>Robert Fischer</a> wrote: Ouch. Of all the nasty things people have said about me because of this post (up to and including calling me a "douchebag"), that's the first one to hit home.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37427">March 10, 2010</a>, joe poki wrote: Robert, I am sorry people called you names but I am not sure what you expected. You published a deliberately controversial post (or may I say a very trollish one?) where you wrote off a whole language using standard (and frankly boooring) points like “it’s too complicated, its syntax is weird, it’s too magical, people write in entirely distinct subsets of the language” for one particular issue you have with it and on top of this, you called the given language's creator a numerous times pretty much clueless when it comes to FP.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37429">March 10, 2010</a>, <a rel="nofollow" target="_blank" href='http://pchiusano.blogspot.com' class='url'>Paul Chiusano</a> wrote: Functional programming just means programming with pure functions (no observable side effects). The alternative is imperative programming - programming with observable side effects. OO is orthogonal - you can program using pure functions operating over objects if you like, or your functions operating over objects can have side effects. Of course, most real programs have some mixture of functional and imperative styles. There are some language features that make programming in a purely functional style more convenient, sure, but basically, with some discipline you can program in this style in any language, Scala (and Perl!) included. My personal opinion is that Scala makes FP pretty convenient - your argument seems to be merely that it's not as convenient as it could be in some instances and therefore doesn't get your official "functional language" stamp. I guess that is fine, although the distinctions you are making seem pretty arbitrary to me.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37430">March 11, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/bhurt-aw/' class='url'>Brian Hurt</a> wrote: I don't see what the big deal with Object Oriented languages is. I mean, you can do Object Oriented programming in languages like C and Pascal- yeah, it's not quite as <em>convenient</em> as doing it in a language like Java or Ruby, but there's no real reason to switch, is there?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37431">March 11, 2010</a>, <a rel="nofollow" target="_blank" href='http://gabrielsw.blogspot.com' class='url'>Gabriel C.</a> wrote: But maybe the only true "popular" OO language is SmallTalk, it could be argued that Java is not really OO, having primitive types and static methods, and many don't really in a fully OO way...</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37432">March 11, 2010</a>, <a rel="nofollow" target="_blank" href='http://gabrielsw.blogspot.com' class='url'>Gabriel C.</a> wrote: Perhaps the difference is that C and Pascal don't have "first class" objects and Java and Ruby have.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37433">March 11, 2010</a>, Paul Kaletta wrote: Well, I've never used Perl 4, but afaik it didn't have a reference variable type and it didn't have lexical scoping, so your examples would not have worked in the current form. Glancing at the Perl 4 manpages it seems that Perl 4 could already pass around code blocks, however it seems to me that you would have had to capture variables manually, which means that closures would have been difficult to do.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#comment-37434">March 11, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/author/bhurt-aw/' class='url'>Brian Hurt</a> wrote: They have structures, and function pointers, and you can put the function pointers in the structures giving you virtual methods. Inheritance is a little tricky, but no one is using that anyways these days, so no problem. Yeah, it's a little bit klunky, but all the important stuff is there, so why do we need to leave C and Pascal again? If you haven't figured it out, I'm making one of my little points by adopting this position.</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on March 6, 2010.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/#respond">http://enfranchisedmind.com/blog/posts/post-functional-scala/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/post-functional-scala/">http://enfranchisedmind.com/blog/posts/post-functional-scala/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (203.215.201.194) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/EHqRUjXQLmY" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/post-functional-scala/</feedburner:origLink></item>
      <item>
         <title>DynamicDomainProperties and the AGPL</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/a8B5xyEw6HQ/</link>
         <description>Why I released the DynamicDomainProperties plugin under the AGPL, and how your business can cope.</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2309</guid>
         <pubDate>Sat, 20 Feb 2010 16:24:33 -0800</pubDate>
         <content:encoded><![CDATA[<p><a rel="nofollow" target="_blank" href="http://www.fsf.org/licensing/licenses/agpl-3.0.html"><img src="http://www.gnu.org/graphics/agplv3-155x51.png"/></a></p>
<p><a rel="nofollow" target="_blank" href='http://www.pledgie.com/campaigns/9065'><img alt='Click here to lend your support to: Un-AGPL DynamicDomainProperties 1.0 and make a donation at www.pledgie.com !' src='http://www.pledgie.com/campaigns/9065.png?skin_name=chrome' border='0'/></a></p>
<p>I just released the DynamicDomainProperties plugin for Grails, which allows domain classes to have dynamic properties. It&#8217;s pretty nifty, if I do say so myself.</p>
<p>Based on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/open-letter-to-burt-beckwith/">my frustration with the Grails plugin culture</a> because of <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/open-source-users/">differing cultural assumptions about open source works</a>, and based on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/">my lack of appreciation for the promises of indirect compensation offered to me as an open source developer</a>, I&#8217;ve decided to release it under the <a rel="nofollow" target="_blank" href="http://www.fsf.org/licensing/licenses/agpl-3.0.html">GNU-Affero GPL 3.0</a>, which is like the GPL but (among other things) requires the source to be available to the users of a web app that use this plugin.</p>
<p>I&#8217;m open to the idea of releasing it under the more &#8220;biz-friendly&#8221; BSD, but then <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/a-defense-of-the-gpl/">I&#8217;m going to want a different form of compensation</a>. So I&#8217;m putting up a bounty via Pledgie: if I was building this plugin as a consultant, it would have cost a client about $2500. So, if the commercial community contributes $2500, I&#8217;ll do a BSD release. Anyone who donates $250 or more gets a single-domain usage license right away.</p>
<p>For more information on the plugin, see <a rel="nofollow" target="_blank" href="http://grails.org/plugin/dynamic-domain-properties">the plugin page on grails.org</a>. (I&#8217;ve had enough difficulty with GitHub&#8217;s wiki freaking out on me and would rather avoid that.)</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/#comment-37286">February 22, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.anyware.co.uk' class='url'>Marc Palmer</a> wrote: I'm interested to see how this pans out Robert - good luck!</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/#comment-37328">March 4, 2010</a>, <a rel="nofollow" target="_blank" href='http://gr8fanboy.wordpress.com/' class='url'>Jeremy Flowers</a> wrote: Way to go. This looks like the way forward to me. In the Microsoft' arena GUI component vendors started to sell there wares this way too, like Infragistics. I always thought plug-ins would have to go the same way to get support for your plug-ins. You have to put food on the table somehow..</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/#comment-37338">March 5, 2010</a>, <a rel="nofollow" target="_blank" href='http://metasieve.wordpress.com/2010/03/05/does-grails-have-a-problem/' class='url'>Does Grails have a problem? &laquo; The MetaSieve Blog</a> wrote: [...] I have time to, I can completely comprehend Robert&#8217;s point of view and his desire to get a different kind of compensation for his open source work. In fact, there should be plenty of space for both approaches (and [...]</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on February 20, 2010.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/#respond">http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/">http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/a8B5xyEw6HQ" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/</feedburner:origLink></item>
      <item>
         <title>I Don’t Get It</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/-I0QQtuirLU/</link>
         <description>Java's open source culture confuses me.</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2276</guid>
         <pubDate>Fri, 05 Feb 2010 12:29:31 -0800</pubDate>
         <content:encoded><![CDATA[<p>When encountering a bug in an open source project, most Java people seem unwilling to either fix it themselves or pay the maintainer to fix it—they&#8217;d rather abandon the project or kludge their software painfully and repetitively. WTF?</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37216">February 5, 2010</a>, <a rel="nofollow" target="_blank" href='http://hamletdarcy.blogspot.com' class='url'>Hamlet D'Arcy</a> wrote: In the past my problem has been that my organization would not let me rely on a personal or nightly build of a project. So when you need a workaround by the end of the week, waiting 2 months for the next release candidate of an OS project is not an option. ... now go release JConch 1.2.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37217">February 5, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.naildrivin5.com/blog' class='url'>Dave</a> wrote: I've encountered this a few times. Sometimes, I'm trying to get things done, so I hack around the problem and then there's not always time to go back and learn a new codebase to submit a patch. Further, having submitted a few patches to a maven plugin (a piece of software I cannot stand, but submitted anyway), it's been months since I uploaded a freakin' zip file to their JIRA and no movement. I also think compared to, say, Ruby, a lot of Java packages are very large and complex. If I find a bug in Spring or Hibernate, my chances of even navigating the codebase to find out where the problem is are nil. And Spring is actually pretty clean code; I mucked through JSCh and the maven release plugin and was HORRIFIED at how awful the code was. And then there's the myriad build systems and spotty tests; One of the Castor devs asked me write a test or he wouldn't accept my patch; my patch was to make his code actually compile. And their tests on trunk (and release tag) didn't pass. Meanwhile, on github, I've submitted patches to things that I wrote and tested in less time than it took to find the svn link on Apache's site. I've also incorporated others changes to my code (that they didn't even submit). Granted these things are not as complex as Spring, but, well, maybe that's a good thing?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37218">February 5, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.naildrivin5.com/blog' class='url'>Dave</a> wrote: @Hamlet D'Arcy in your case, I have imported the released version I'm using into our company's svn repo and made changes I needed against that, then deployed THAT to our maven repo. It was painful, but worked.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37219">February 5, 2010</a>, <a rel="nofollow" target="_blank" href='http://twitter.com/RobertFischer' class='url'>Robert Fischer</a> wrote: Argh. I've totally forgotten about JConch 1.2. Just released it. It's now a Gradle-based build (I wanted to OSGi-ify the project and have a Maven repo).</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37220">February 5, 2010</a>, <a rel="nofollow" target="_blank" href='http://spockframework.org' class='url'>Peter Niederwieser</a> wrote: From my experience, most developers aren't even willing to take the time to report a bug they encounter...</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37222">February 6, 2010</a>, <a rel="nofollow" target="_blank" href='http://plasmasturm.org/' class='url'>Aristotle Pagaltzis</a> wrote: I agree with Peter – I actually <a rel="nofollow" target="_blank" href="http://twitter.com/apag/status/7101875141">tweeted the same observation</a> just a few weeks ago. I got <a rel="nofollow" target="_blank" href="http://twitter.com/jrockway/status/7101912403">one response to that</a> that <a rel="nofollow" target="_blank" href="http://twitter.com/apag/status/7360563175">didn’t satisfy me either</a>. It’s not limited to Java either.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37233">February 6, 2010</a>, <a rel="nofollow" target="_blank" href='http://blog.james-carr.org' class='url'>James Carr</a> wrote: Yeah... this has often surprised me as well. I've witnessed a team try to use some open source solution and give up because of a minor bug and go to a much more difficult to use proprietary solution (which amusingly had more critical bugs). I was also surprised when at my current client site they actually asked me spend a week working on fixing a bug in an open source project and submit a patch... that's definitely the best attitude to have. :)</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#comment-37413">March 8, 2010</a>, <a rel="nofollow" target="_blank" href='http://mcherm.com/' class='url'>Michael Chermside</a> wrote: For projects in ALL languages, the difficulty in getting a patch accepted is a genuine issue (and is difficult to solve). There is a sweet-spot of small, recent projects that accept patches easily. Older projects are often neglected (or abandoned) by their original authors, which makes accepting patches difficult. Larger projects necessarily set standards (like requiring unit tests or moderately complicated review processes, or certain coding standards) which not every patch will meet. The problem is not easily solved because these are inherent problems rather than just projects being obstinate. Meanwhile, Java programmers are probably worse because (1) many well-known open-source Java projects are large and corporately sponsored which makes it difficult to get them to accept patches, and (2) many Java programmers work in corporate environments where it is difficult to get "permission" to contribute to an open source project. Simply not being in the habit of doing so makes the practice less likely than with other languages.</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on February 5, 2010.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/#respond">http://enfranchisedmind.com/blog/posts/i-dont-get-it/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/i-dont-get-it/">http://enfranchisedmind.com/blog/posts/i-dont-get-it/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/-I0QQtuirLU" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/i-dont-get-it/</feedburner:origLink></item>
      <item>
         <title>The Gradual Death of IE6 Just Got a Nitro Boost</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/wu8aljUC9PM/</link>
         <description>Google is killing off IE6 for Google Apps. Excellent!</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2273</guid>
         <pubDate>Tue, 02 Feb 2010 17:51:27 -0800</pubDate>
         <content:encoded><![CDATA[<p>From <a rel="nofollow" target="_blank" href="http://googleenterprise.blogspot.com/2010/01/modern-browsers-for-modern-applications.html">the Official Google Enterprise Blog</a>:</p>
<blockquote><p>Many other companies have already stopped supporting older browsers like Internet Explorer 6.0 as well as browsers that are not supported by their own manufacturers. We’re also going to begin phasing out our support, starting with Google Docs and Google Sites. As a result you may find that from March 1 key functionality within these products &#8212; as well as new Docs and Sites features &#8212; won’t work properly in older browsers.</p></blockquote>
<p>w00t! Die, IE6, die!</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/google-says-ie6-must-die/#comment-37257">February 15, 2010</a>, <a rel="nofollow" target="_blank" href='http://www.colinharrington.net' class='url'>Colin Harrington</a> wrote: Dear IE6: You are dead to me. goto /dev/null Thank you. ~ The Interwebs</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on February 2, 2010.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/google-says-ie6-must-die/#respond">http://enfranchisedmind.com/blog/posts/google-says-ie6-must-die/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/google-says-ie6-must-die/">http://enfranchisedmind.com/blog/posts/google-says-ie6-must-die/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/wu8aljUC9PM" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/google-says-ie6-must-die/</feedburner:origLink></item>
      <item>
         <title>Gradle-Plugins 0.5.1 released</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/SHNcz4hfghM/</link>
         <description>My Gradle plugins have been updated to handle a missing gems home.</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2111</guid>
         <pubDate>Tue, 05 Jan 2010 07:35:23 -0800</pubDate>
         <content:encoded><![CDATA[<p>Thanks to <a rel="nofollow" target="_blank" href="http://jeppenejsum.wordpress.com/">Jeppe Nejsum Madsen</a>, the <a rel="nofollow" target="_blank" href="http://github.com/RobertFischer/gradle-plugins">Gradle-Plugins</a> just released version 0.5.1. It&#8217;s a minor bugfix release: if you didn&#8217;t have a <code>GEMS_HOME</code> kicking around anywhere on your system, we threw a <a rel="nofollow" target="_blank" href="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/NullPointerException.html">NPE</a>. The solution was to make <a rel="nofollow" target="_blank" href="http://github.com/RobertFischer/gradle-plugins/blob/master/src/main/groovy/ProjectExtPlugin.groovy"><code>project.tryRelativePath</code></a> handle <code>null</code> input more nicely.</p>
<hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on January 5, 2010.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/gradle-plugins-0-5-1-released/#respond">http://enfranchisedmind.com/blog/posts/gradle-plugins-0-5-1-released/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/gradle-plugins-0-5-1-released/">http://enfranchisedmind.com/blog/posts/gradle-plugins-0-5-1-released/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/SHNcz4hfghM" height="1" width="1"/>]]></content:encoded>
         <category>Gradle</category>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/gradle-plugins-0-5-1-released/</feedburner:origLink></item>
      <item>
         <title>The New Wheel: A Software Engineering Parable</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/aloPz6zx8-Q/</link>
         <description>In the early days of humankind, a young man excitedly ran up to the leader of the tribe. "You won't believe it! I have an awesome invention! See, I know that our parents invented the wheel, but the wheel has all kinds of problems. It's too hard to produce. It rolls away on you when you want to stand still. It's hard to understand and to describe to people—'it's like a thin slice of smooth rock with a hole in the middle' isn't exactly easy to grok."</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2089</guid>
         <pubDate>Wed, 16 Dec 2009 07:17:43 -0800</pubDate>
         <content:encoded><![CDATA[<p>My co-author on this blog, <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/bhurt-aw/">Brian Hurt</a>, is my software mentor. He taught me everything important that I&#8217;ve learned in software development. I&#8217;ve been a pretty dense student: I&#8217;ve consistently rebelled against his advice only to find him proven right in the long haul. Of course, I then proceed to rebel against the next piece of advice. Sooner or later, you&#8217;d think I&#8217;d learn.</p>
<p>Anyway, of all the parables and the jokes and the pithy aphorisms he&#8217;s told me, this is the one that I&#8217;ve found most key to software engineering, and it jumped to mind after reading <a rel="nofollow" target="_blank" href="http://old.nabble.com/Silly-question...-td26810212.html">Marc&#8217;s recent groovy-user post</a>.</p>
<hr />
In the early days of humankind, a young man excitedly ran up to the leader of the tribe. &#8220;You won&#8217;t believe it! I have an awesome invention! See, I know that our parents invented the wheel, but the wheel has all kinds of problems. It&#8217;s too hard to produce. It rolls away on you when you want to stand still. It&#8217;s hard to understand and to describe to people—&#8217;it&#8217;s like a thin slice of smooth rock with a hole in the middle&#8217; isn&#8217;t exactly easy to grok.&#8221;
<p>The leader of the tribe looked askance at the young man. &#8220;Are you telling me that you have improved on the wheel?&#8221;</p>
<p>The young man nodded in excitement, &#8220;Yeah! You wouldn&#8217;t believe it! I just went back to square one. I started from scratch with the generation of experience and knowing all these problems we have with wheels, and I went off and developed a proof of concept, and it seems to be working out pretty well. I&#8217;ve been showing it to other people, and they love it, so I&#8217;ve got a prototype that I want to show you. This new wheel is really the wheel of the people—the elders won&#8217;t be the only people who can invent new things based around wheels anymore! Even better, all my friends agree that the new design solves the problems we have with wheels: we can produce them at speed, it doesn&#8217;t roll away when we want to stand still, and it&#8217;s easier to understand!&#8221;</p>
<p>The leader of the tribe did not seem impressed. &#8220;But what new design improves on the wheel?&#8221;</p>
<p>&#8220;Well, my new wheel is just like the old wheel—but this time, it&#8217;s <em>square</em>!&#8221;</p>
<hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on December 16, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/new-wheel/#respond">http://enfranchisedmind.com/blog/posts/new-wheel/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/new-wheel/">http://enfranchisedmind.com/blog/posts/new-wheel/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/aloPz6zx8-Q" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/new-wheel/</feedburner:origLink></item>
      <item>
         <title>The Self-Destructive Side of Open Source Software</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/-4FNvXxpP0g/</link>
         <description>There's a bit of a misunderstanding about the economics open source software. Most importantly, people seem to be missing that commercializing open source software seems to be fundamentally self-destructive.</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2061</guid>
         <pubDate>Mon, 14 Dec 2009 20:07:30 -0800</pubDate>
         <content:encoded><![CDATA[<p>There was an interesting conversation today on Twitter between <a rel="nofollow" target="_blank" href="http://hamletdarcy.blogspot.com/">Hamlet D&#8217;Arcy</a> (<a rel="nofollow" target="_blank" href="http://twitter.com/HamletDRC">@HamletDRC</a>), <a rel="nofollow" target="_blank" href="http://www.anyware.co.uk/">Marc Palmer</a> (<a rel="nofollow" target="_blank" href="http://twitter.com/wangjammer5">@WangJammer5</a>), and <a rel="nofollow" target="_blank" href="http://smokejumperit.com">me</a> (<a rel="nofollow" target="_blank" href="http://twitter.com/RobertFischer">@RobertFischer</a>). Marc and I were riffing on our regular theme (our lack of direct financial return from our OSS contributions), and the following conversation ensued. It&#8217;s been edited for length: the whole conversation would be <a rel="nofollow" target="_blank" href="http://bit.ly/8clJSJ">here on search.twitter.com</a> if search.twitter.com worked.</p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-2-300x157.png"/></p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-4-300x158.png"/></p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-3-300x153.png"/></p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-7-300x160.png"/></p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-1-300x142.png"/></p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-5-300x159.png"/></p>
<p><img src="http://enfranchisedmind.com/blog/wp-content/uploads/2009/12/Picture-6-300x152.png"/></p>
<p>That conversation, along with the comments on Marc&#8217;s <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/">“Do we need a commercial market for Grails Plugins?”</a> post, suggest that there&#8217;s a bit of a misunderstanding about the economics open source software. Most importantly, people seem to be missing that commercializing open source software seems to be fundamentally self-destructive.<span id="more-2061"></span></p>
<p>Take the standard recommendation to support yourself on OSS: offer consulting/training/speaking. The problem with this approach is that you&#8217;re directly competing with the time you have to do your development, so the more successful you are, the less time you have for open source. Building a consulting business and prepping presentations and training is hard and time-consuming work and it eats up a lot of your life. There was a blog post a while back (I&#8217;ve lost it) which event went so far as to argue that there simply isn&#8217;t enough time to be an accomplished open source project lead <em>and</em> be an accomplished writer/speaker. <a rel="nofollow" target="_blank" href="http://www.biblegateway.com/passage/?search=Matthew%206:24&#038;version=NASB">You can&#8217;t serve God and Mammon.</a> This has been my experience: I have to make decisions about where to spend my time, and my open source projects are consistently on the losing end of that stick in favor of paid gigs (doubly so since the economic downturn hit my and my wife&#8217;s consulting pipelines about a year ago). This dedication of my time to paid gigs over OSS is fine by me—I&#8217;m making the decision about how to spend my time with intent and forethought—but it does show that as a way to &#8220;support yourself on OSS&#8221;, consulting/training/speaking fails because it wipes the OSS off the map.</p>
<p>There is a point where the speaking/training/consulting balance flips is when you can subcontract out the training and consulting, leaving the core developers to primarily develop. This requires a level of adoption and need that is a lot larger than a Grails plugin or minor Java library is going to have.</p>
<p>In addition, I always consider the training/speaking/consulting approach to be a bit of a conflict of interest. If you write a solid, accessible peace of software, what&#8217;s the value in your consulting? And if you&#8217;re consulting, aren&#8217;t you even more interested in just your own needs to the exclusion of what the community may want? The prime example for the latter is the conspicuous change from Jetty to Tomcat for the Grails default server right after SpringSource purchased them. Seems like the existence of <a rel="nofollow" target="_blank" href="http://www.springsource.com/products/tcserver">Spring tcserver</a> might have something to do with that&#8230;</p>
<p>So, if we toss consulting/training/speaking out, I&#8217;m aware of basically have two approaches to making money doing open source software.</p>
<p>First is dual-licensing. <a rel="nofollow" target="_blank" href="http://www.zedshaw.com/blog/2009-07-13.html">Zed Shaw makes a good case for it</a>, and I&#8217;ve been thinking about giving it a shot with some of my projects. <a rel="nofollow" target="_blank" href="http://prng.blogspot.com/2009/12/how-to-screw-your-open-source-software.html">A post by Greg Stein</a> that made its rounds on Twitter today argues the GPL can screw consumers because you&#8217;re basically banking on the benevolent dictator remaining benevolent. I&#8217;m unimpressed by the argument, which is basically whining that the GPL is too strict a definition of open source for these proprietary-software companies. Greg Stein thinks companies, <em>who are taking open source and making money off it without returning to the community</em>, are somehow &#8220;misled&#8221; when they rejected the GPL and opted instead to pay for a more permissive license. I have little sympathy for them. If they don&#8217;t like the GPL, <a rel="nofollow" target="_blank" href="http://www.postgresql.org/about/licence">use the BSD-licensed postgreSQL</a>. In any case, the dual licensing approach seems like a reasonable way to go.</p>
<p>My reluctance to dual-licensing approach is threefold: 1) releasing code under the GPL means having to enforce GPL violations when/if I find them; 2) adoption is stunted, because many companies run screaming from software which even uses the characters &#8216;G&#8217;, &#8216;P&#8217;, &#8216;L&#8217; in sequence, even if there is an alternative license they could buy into (another self-destructive side of open source software); 3) in the web development space, the GPL basically has no teeth thanks to the so-called <a rel="nofollow" target="_blank" href="http://www.google.com/search?q=saas+loophole">SaaS Loophole</a>: you don&#8217;t distribute the software but you charge people to use it, and you eventually sell the company (not the software), so the GPL never comes into effect. But it&#8217;s better than nothing.</p>
<p>Another alternative is <a rel="nofollow" target="_blank" href="http://groups.google.com/group/clojure/msg/5f40e7048e1f774e">Rich Hickey&#8217;s &#8220;Funding Clojure 2010&#8243; approach</a>, which is basically begging for donations—becoming an Open Source Friar of sorts. Rich Hickey may be able to get that to work, but I don&#8217;t think there&#8217;s a big enough audience for my work to get that to happen.</p>
<p>An alternatives along the same line is crowd-funding improvements, but that two critical failure points. First, developer time isn&#8217;t cheap—I have to feed myself and my family. Despite the fact that my open source effort might save companies dozens of hours of your developers&#8217; time (assuming they trust their developers to do it, which many don&#8217;t!), companies seem to balk at reasonable rates. This is doubly-true in the web sector, where &#8220;companies&#8221; often means &#8220;single-person self-funded start-ups&#8221;. Second is that there&#8217;s a lot of work involved in avoiding bit-rot on a project which doesn&#8217;t qualify as an improvement. When a new version of Grails comes out, I have to go through all my plugins and make sure they still work right, <a rel="nofollow" target="_blank" href="http://jira.codehaus.org/browse/GRAILS-5545">often discovering bugs in Grails in the process</a>. Who is going to want to fund that?</p>
<p>So, if we&#8217;re coming up with a way to support ourselves while doing open source software development, we have two critical requirements.</p>
<ol>
<li>Our income needs to come from developing on the open source project itself. Auxiliary income sources ultimately detract from the open source development itself.</li>
<li>Our income needs to be ongoing, not single-shot. The shrink-wrapped software model doesn&#8217;t work, because the open source software I&#8217;m producing isn&#8217;t a self-contained product but an adjunct to another piece of software.</li>
</ol>
<p>So, I&#8217;m really not sure what to do with this. A subscription model seems to be in alignment with our requirements, but how would that work? Some kind of patronage would work well, too [<b>EDIT</b>: (see comments)], but is that going to fly in this economic market? I just don&#8217;t know.</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37091">December 15, 2009</a>, Eric Pederson wrote: What about dual licensing with AGPL?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37092">December 15, 2009</a>, Marc Stock wrote: "Some kind of patronage would work well, too, but is that going to fly in this economic market?" No, it won't. Of course, it won't fly in a good market either. I've found developers to be unbelievably cheap bastards. You could produce a tool that would save them 2 hours of time a day and unless they can get it for free, they will tell you to f* off. You may think I'm overstating things, but I'm really not. I've tried to convince people to buy tools with clear value many many times in my career and it just doesn't work. I'm one of the only developers I know of on the planet who actually budgets money every year to buy whatever tools, libraries, etc. I want. That budget is generally $1000 per year. I challenge you to find a developer who even sets aside $50 per year. If you ask them why, they will tell you that their company must by it for them. It's funny that car mechanics (who make a third of our income) buy all their own tools (yes, repair shops almost always require mechanics to pay for their own tools) which adds up to thousands of dollars and don't bat an eye because they know that's what they need to get their job done efficiently. There's a big problem in developer culture that needs to change but I don't see any change on the horizon.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37093">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: @Eric Pederson The AGPL does solve the SaaS loophole: see <a rel="nofollow" target="_blank" href="http://www.fsf.org/licensing/licenses/gpl-faq.html#AGPLv3InteractingRemotely">In AGPLv3, what counts as “interacting with [the software] remotely through a computer network?”</a>. So that's one issue down. Like I said, I'm inclined to try the dual licensing route: I just don't have a lot of hope for it.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37094">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: @Marc That's been my experience, too: it's hard to get money out of the developer community unless you've got a cult of personality which drive people to your products *cough*<a rel="nofollow" target="_blank" href="http://37signals.com">37Signals</a>*cough*. IntelliJ seems to have bested your cynicism, but that's about the only one I can point to. The "patronage" model I was referring to isn't the kind of watered-down meaning of "WalMart thanks you for your patronage". I'm talking about a full-fledged "I want to hire this developer to do cool stuff to solve our problems, so that the cool stuff flows into our business first". Even ignoring explicit brain shops, there are a few de facto patronage relationships out there I've seen—usually someone with the title of "architect" who solves problems in the large by providing tools for work in the small. If that kind of position could be merged with OSS work, that'd be my ideal kind of situation.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37095">December 15, 2009</a>, Marc Stock wrote: I can't even get most developers to *look* at IntelliJ, let alone buy it. Almost every one tells me that either Eclipse is perfectly fine so there's no need to look elsewhere or eclipse is free so how can something that can only be "incrementally better" justify the price. I don't even try to convince people any more. I can also name at least a half dozen developers who were given free licenses to IntelliJ who won't even download it. Your patronage idea is cool although I'm not sure how you sell it in today's world. It's a pretty old school idea though. Patronage was how most artists were funded through middle ages and renaissance, as I understand it.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37097">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: Despite your experiences, JetBrains seems to be doing just fine with it. I see a lot of IntelliJ in the wild on the NFJS tour. And especially in the early days of Groovy/Grails, IntelliJ was pretty much ubiquitous on in my contracting world.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37098">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: BTW, the patronage model is the basic model underlying my <a rel="nofollow" target="_blank" href="http://smokejumperit.com/grails-retainer/">Grails Retainer services</a>. And that's working out somewhat well, although work hasn't been as long-term as I had envisioned.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37099">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://hamletdarcy.blogspot.com' class='url'>Hamlet D&#92;'Arcy</a> wrote: &gt;&gt; This has been my experience: I have to &gt;&gt; make decisions about where to spend my time Congratulations on being an adult: the long era in your life where you have to make tough decisions between what makes you happy and what your obligations are as a human. If you would like to see this effect magnified then you should have children. Then you'll really be confronted with tough decisions about what you want versus what your family needs. I, for one, have enjoyed this period in my life. I feel that finding the balance between work, my daughter, graduate school at night, my wife, and open source software has made me a better person. I don't really have friends, but that was just one of the tough decisions I've had to make. Honestly, you and the gang at Groovy.MN are my closest friends, and we see each other less than once a month! Ok, I'm officially sad now...</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37100">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://hamletdarcy.blogspot.com' class='url'>Hamlet D&#92;'Arcy</a> wrote: And here is the quote that popped into my quote a day just now: I don't know why we are here, but I'm pretty sure that it is not in order to enjoy ourselves. - Ludwig Wittgenstein</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37101">December 15, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: My question isn't about what makes me happy vs. what doesn't: my question is how to we build a sustainable OSS ecosystem, especially in the context of Grails plugins but also with respect to things like Rich Hickey's work on Clojure. In looking at the OSS ecosystem, we have two choices: 1) we accept that OSS/Grails plugin dev is a "free time only" enterprise; or 2) we need to have a way for people to support themselves. If we accept #1, we need to be honest about that and build a liveness check into the Grails plugin ecosystem, because the 300+ plugins are actively and quickly bit-rotting and that's just how reality works. Also, if we are accepting #1, then people need to back the Hell off and not be so demanding of the plugin developers (see the <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/fyi-my-open-source-users/">Free Toilet post</a>). If we accept #2, then we need to figure out how people are going to support themselves, which is what this post is exploring. And I'm noting that relying on consulting and speaking to support OSS is destructive to the projects: it's not a workable model/expectation for OSS support, at least in the world of the Grails plugin ecosystem.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#comment-37278">February 20, 2010</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/dynamicdomainproperties-grails-plugin-agpl/' class='url'>DynamicDomainProperties and the AGPL</a> wrote: [...] plugin culture because of differing cultural assumptions about open source works, and based on my lack of appreciation for the promises of indirect compensation offered to me as an open source de..., I&#8217;ve decided to release it under the GNU-Affero GPL 3.0, which is like the GPL but (among [...]</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on December 14, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/#respond">http://enfranchisedmind.com/blog/posts/self-destructive-oss/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/self-destructive-oss/">http://enfranchisedmind.com/blog/posts/self-destructive-oss/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/-4FNvXxpP0g" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/self-destructive-oss/</feedburner:origLink></item>
      <item>
         <title>Marc Palmer: “Do we need a commercial market for Grails Plugins?”</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/jwsR7r8svGE/</link>
         <description>If you are a Grails developer who hasn&amp;#8217;t read Marc Palmer&amp;#8217;s blog post, &amp;#8220;Do we need a commercial market for [...]</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2020</guid>
         <pubDate>Fri, 11 Dec 2009 12:02:56 -0800</pubDate>
         <content:encoded><![CDATA[<p>If you are a Grails developer who hasn&#8217;t read Marc Palmer&#8217;s blog post, &#8220;<a rel="nofollow" target="_blank" href="http://www.anyware.co.uk/2005/2009/12/11/do-we-need-a-commercial-market-for-grails-plugins/">Do we need a commercial market for Grails Plugins?</a>&#8220;, you need to do so. Now. I&#8217;ll wait.</p>
<p>The crux of the problem is adequately described in Marc&#8217;s <a rel="nofollow" target="_blank" href="http://graphjam.com">GraphJam</a>-worthy graph:<br />
<a rel="nofollow" target="_blank" href="http://www.anyware.co.uk/2005/wp-content/uploads/2009/12/Plugin-time.ograph1.png "><img width="100%" src="http://www.anyware.co.uk/2005/wp-content/uploads/2009/12/Plugin-time.ograph1.png"></a></p>
<p>The problem is, this leads to a bunch of great ideas that are 3/4ths implemented, with lots of unimplemented great ideas still sitting around and twiddling their thumbs. (<a rel="nofollow" target="_blank" href="http://grails.org/plugin/autobase">Autobase</a>, I&#8217;m looking at you.) This does damage to the Grails ecosystem, starting with a lack of trust in plugins and ending with <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/fyi-my-open-source-users/">burnt out plugin developers angrily reclaiming their free time</a>. So, how do we help the original developer make time for plugins, or how can we get other developers to step up and contribute (despite the <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/open-source-users/">consumer-developer paradigm</a>)? That&#8217;s what Marc goes looking into, and both the original post and the comments are extremely insightful.</p>
<p>[<b>PS:</b> I'm thinking about integrating some link sharing capabilities into EnfranchisedMind so that I can queue up and share a bunch of good posts like this every month or so. Thoughts? <em>—Admin</em>]</p>
<p>[<b>PPS:</b> I've closed comments. Go post them on Marc's blog.<em>—Author</em>]</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/#comment-37089">December 14, 2009</a>, <a rel="nofollow" target="_blank" href='http://enfranchisedmind.com/blog/posts/self-destructive-oss/' class='url'>Enfranchised Mind &raquo; The Self-Destructive Side of Open Source Software</a> wrote: [...] conversation, along with the comments on Marc&#8217;s “Do we need a commercial market for Grails Plugins?” post, suggest that there&#8217;s a bit of a misunderstanding about the economics open source [...]</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on December 11, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/#respond">http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/">http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (98.136.63.35) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/jwsR7r8svGE" height="1" width="1"/>]]></content:encoded>
         <category>Software Business</category>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/commercial-grails-plugins/</feedburner:origLink></item>
      <item>
         <title>setJDK/setGrails</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/BURWMrMuH-8/</link>
         <description>I spend a lot of time bouncing between different versions of JDKs and different versions of Grails. To make [...]</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2018</guid>
         <pubDate>Fri, 11 Dec 2009 05:01:11 -0800</pubDate>
         <content:encoded><![CDATA[<p>I spend a lot of time bouncing between different versions of JDKs and different versions of Grails. To make my life easier, I&#8217;ve got these files in my bin directory.</p>
<h3>setJDK</h3> <div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color:#666666;font-style:italic;">#!/bin/sh</span>
&nbsp;
<span style="color:#7a0874;font-weight:bold;">cd</span> <span style="color:#000000;font-weight:bold;">/</span>System<span style="color:#000000;font-weight:bold;">/</span>Library<span style="color:#000000;font-weight:bold;">/</span>Frameworks<span style="color:#000000;font-weight:bold;">/</span>JavaVM.framework<span style="color:#000000;font-weight:bold;">/</span>Versions
&nbsp;
<span style="color:#007800;">CURJDK</span>=<span style="color:#ff0000;">"<span style="color:#780078;">`readlink CurrentJDK`</span>"</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Current JDK version: <span style="color:#007800;">$CURJDK</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">if</span> <span style="color:#7a0874;font-weight:bold;">&#91;</span> <span style="color:#ff0000;">"$1"</span> == <span style="color:#ff0000;">""</span> <span style="color:#7a0874;font-weight:bold;">&#93;</span>; <span style="color:#000000;font-weight:bold;">then</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Installed versions:
<span style="color:#c20cb9;font-weight:bold;">ls</span>
<span style="color:#7a0874;font-weight:bold;">exit</span>
<span style="color:#000000;font-weight:bold;">fi</span>
&nbsp;
<span style="color:#007800;">VERFOUND</span>=<span style="color:#000000;font-weight:bold;">`</span><span style="color:#c20cb9;font-weight:bold;">ls</span> <span style="color:#000000;font-weight:bold;">|</span> <span style="color:#c20cb9;font-weight:bold;">grep</span> $<span style="color:#000000;">1</span> <span style="color:#000000;font-weight:bold;">|</span> <span style="color:#c20cb9;font-weight:bold;">head</span> <span style="color:#660033;">-n</span> <span style="color:#000000;">1</span><span style="color:#000000;font-weight:bold;">`</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">if</span> <span style="color:#7a0874;font-weight:bold;">&#91;</span> <span style="color:#ff0000;">"<span style="color:#007800;">$VERFOUND</span>"</span> <span style="color:#000000;font-weight:bold;">!</span>= <span style="color:#ff0000;">"$1"</span> <span style="color:#7a0874;font-weight:bold;">&#93;</span>; <span style="color:#000000;font-weight:bold;">then</span>
<span style="color:#007800;">BASE</span>=<span style="color:#ff0000;">"<span style="color:#780078;">`basename $0`</span>"</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Error: Could not change JDK-- version $<span style="color:#000000;">1</span> not installed<span style="color:#000000;font-weight:bold;">!</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Run <span style="color:#007800;">$BASE</span> without arguments to see a list of installed versions.
<span style="color:#7a0874;font-weight:bold;">exit</span> <span style="color:#000000;">127</span> <span style="color:#000000;font-weight:bold;">fi</span>
&nbsp;
<span style="color:#7a0874;font-weight:bold;">echo</span> You must now enter your Mac OS X password to change the JDK.
<span style="color:#c20cb9;font-weight:bold;">sudo</span> <span style="color:#c20cb9;font-weight:bold;">ln</span> <span style="color:#660033;">-fhsv</span> $<span style="color:#000000;">1</span> CurrentJDK
<span style="color:#c20cb9;font-weight:bold;">sudo</span> <span style="color:#c20cb9;font-weight:bold;">ln</span> <span style="color:#660033;">-fhsv</span> $<span style="color:#000000;">1</span> Current</pre></div></div> <p>I found that <code>setJDK</code> code somewhere on the internet, but I&#8217;m not really sure where and I had trouble finding it again. So I thought I&#8217;d share it here.</p>
<p>To integrate <a rel="nofollow" target="_blank" href="http://landonf.bikemonkey.org/static/soylatte/">SoyLatte Java</a> (which you probably want to be using anyway), just create a symlink in <code>/System/Library/Frameworks/JavaVM.framework/Versions</code> that points to your SoyLatte install.</p>
<h3>setGrails</h3>
<p>I&#8217;ve modified that script a bit to allow me to modify the version of Grails to use. This script assumes that you have your Grails distributions stored in <code>BINDIR</code>, and you&#8217;ve added <code>$BINDIR/grails/bin</code> to <code>PATH</code>. Once that&#8217;s set up, this script works like a charm:</p> <div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color:#666666;font-style:italic;">#!/bin/sh</span>
&nbsp;
<span style="color:#7a0874;font-weight:bold;">cd</span> <span style="color:#007800;">$BINDIR</span>
&nbsp;
<span style="color:#007800;">CURGRAILS</span>=<span style="color:#ff0000;">"<span style="color:#780078;">`readlink grails`</span>"</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Current Grails version: <span style="color:#007800;">$CURGRAILS</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">if</span> <span style="color:#7a0874;font-weight:bold;">&#91;</span> <span style="color:#ff0000;">"$1"</span> == <span style="color:#ff0000;">""</span> <span style="color:#7a0874;font-weight:bold;">&#93;</span>; <span style="color:#000000;font-weight:bold;">then</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Installed versions:
<span style="color:#7a0874;font-weight:bold;">echo</span> <span style="color:#000000;font-weight:bold;">`</span><span style="color:#c20cb9;font-weight:bold;">ls</span> <span style="color:#660033;">-1</span> <span style="color:#000000;font-weight:bold;">|</span> <span style="color:#c20cb9;font-weight:bold;">grep</span> <span style="color:#ff0000;">"grails-"</span><span style="color:#000000;font-weight:bold;">`</span>
<span style="color:#7a0874;font-weight:bold;">exit</span>
<span style="color:#000000;font-weight:bold;">fi</span>
&nbsp;
<span style="color:#007800;">VERFOUND</span>=<span style="color:#000000;font-weight:bold;">`</span><span style="color:#c20cb9;font-weight:bold;">ls</span> <span style="color:#660033;">-1</span> <span style="color:#000000;font-weight:bold;">|</span> <span style="color:#c20cb9;font-weight:bold;">grep</span> $<span style="color:#000000;">1</span> <span style="color:#000000;font-weight:bold;">|</span> <span style="color:#c20cb9;font-weight:bold;">head</span> <span style="color:#660033;">-n</span> <span style="color:#000000;">1</span><span style="color:#000000;font-weight:bold;">`</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">if</span> <span style="color:#7a0874;font-weight:bold;">&#91;</span> <span style="color:#ff0000;">"<span style="color:#007800;">$VERFOUND</span>"</span> <span style="color:#000000;font-weight:bold;">!</span>= <span style="color:#ff0000;">"grails-$1"</span> <span style="color:#7a0874;font-weight:bold;">&#93;</span>; <span style="color:#000000;font-weight:bold;">then</span>
<span style="color:#007800;">BASE</span>=<span style="color:#ff0000;">"<span style="color:#780078;">`basename $0`</span>"</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Error: Could not change Grails-- version $<span style="color:#000000;">1</span> not installed<span style="color:#000000;font-weight:bold;">!</span>
<span style="color:#7a0874;font-weight:bold;">echo</span> Run <span style="color:#007800;">$BASE</span> without arguments to see a list of installed versions.
<span style="color:#7a0874;font-weight:bold;">exit</span> <span style="color:#000000;">127</span> <span style="color:#000000;font-weight:bold;">fi</span>
&nbsp;
<span style="color:#c20cb9;font-weight:bold;">ln</span> <span style="color:#660033;">-fhsv</span> <span style="color:#ff0000;">"grails-$1"</span> grails</pre></div></div> <h3>Finger-Saving Tips</h3>
<p>If you&#8217;re really hardcore, add these lines to <code>~/.profile</code>:</p> <div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color:#7a0874;font-weight:bold;">alias</span> <span style="color:#007800;">sg</span>=setGrails
<span style="color:#7a0874;font-weight:bold;">alias</span> <span style="color:#007800;">sj</span>=setJDK</pre></div></div> <hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37068">December 11, 2009</a>, Fred wrote: Nice. Command line tooling just doesn't seem to be hotness in the Java community, so tips like this don't get shared too often, it seems to me. I like!</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37069">December 11, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: Too many people are too dependent on IDEs. I find more power with less annoyance in the command line. But, y'know, I started my programming life pissing people off in perl (<a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/a-defense-of-prototypes/">e.g.</a>) instead of pissing people off on the JVM, so I have an intimacy with the command line I don't find in a lot of Java or .Net developers.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37070">December 11, 2009</a>, <a rel="nofollow" target="_blank" href='http://gabe97330.blogspot.com' class='url'>Gabe Beged-Dov</a> wrote: Hi Robert, A similar version that separates the "default" (relink) from setversion is described in this post: http://old.nabble.com/setgrails-version-%28bash%29-script-with-completion-td26410455.html Best regards, Gabe</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37072">December 11, 2009</a>, <a rel="nofollow" target="_blank" href='http://nakkaya.com' class='url'>Nurullah Akkaya</a> wrote: setJDK script is from, http://www.macosxhints.com/article.php?story=20060121171126988</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37074">December 11, 2009</a>, <a rel="nofollow" target="_blank" href='http://gabe97330.blogspot.com' class='url'>Gabe Beged-Dov</a> wrote: The setjdk script (http://docs.codehaus.org/display/ninja/setjdk) referenced in my grails-user post (see earlier comment) supports setting a default version as well as setting a per-process version. It also has command completion. Best regards, Gabe</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37075">December 11, 2009</a>, <a rel="nofollow" target="_blank" href='http://blog.headius.com' class='url'>Charles Oliver Nutter</a> wrote: Try Nick Sieger's "pickjdk" script...I love it. I made some modifications to allow selecting by number in one command as well: http://gist.github.com/143128</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37076">December 11, 2009</a>, <a rel="nofollow" target="_blank" href='http://naleid.com/blog' class='url'>Ted Naleid</a> wrote: Nice! I did <a rel="nofollow" target="_blank" href="http://naleid.com/blog/2009/03/08/bashzsh-aliases-to-switch-groovy-and-grails-version/">something similar</a> a while ago where it switches both the groovy and grails symlinks with one command. I like to have them in sync and can never quite remember which dot version of groovy belongs with a grails version. Mine is more manual than this though because it can't interrogate what's actually installed in the directory, you need to manually add an alias pairing the particular groovy and grails versions together. Somethign I could automate with a little awk/sed magic and looking in the lib dir, but the pain hasn't quite hit that level yet :). Thanks for sharing. I love seeing other shell tricks for coding.</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#comment-37077">December 12, 2009</a>, <a rel="nofollow" target="_blank" href='http://gabe97330.blogspot.com' class='url'>Gabe Beged-Dov</a> wrote: The problem with relinking is that it is global so you can't have several concurrent shells using different versions of the framework. That's where the distinction of setdefault vs. setversion is useful. Also very nice to have completion.</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on December 11, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#respond">http://enfranchisedmind.com/blog/posts/setjdk-setgrails/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/setjdk-setgrails/">http://enfranchisedmind.com/blog/posts/setjdk-setgrails/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (87.250.252.241) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/BURWMrMuH-8" height="1" width="1"/>]]></content:encoded>
         <category>Code Samples</category>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/setjdk-setgrails/</feedburner:origLink></item>
      <item>
         <title>Oh, Gradle, You Made My Heart Skip a Beat</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/EOPIJeG2RMw/</link>
         <description>As I just mentioned, I&amp;#8217;ve been working on some Gradle plugins. I&amp;#8217;ve been using Gradle in my polyglot programming [...]</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2009</guid>
         <pubDate>Fri, 27 Nov 2009 07:28:59 -0800</pubDate>
         <content:encoded><![CDATA[<p>As I just mentioned, <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/">I&#8217;ve been working on some Gradle plugins</a>. I&#8217;ve been using Gradle in my polyglot programming book, and there&#8217;s a stunt (namely, running Cucumber in a Java/Groovy/Scala build) that I&#8217;d like the user to be able to do without too much hassle. The easiest way is to say, &#8220;Hey, use this plugin and let the magic fly&#8221;.</p>
<p>In doing development, I&#8217;m spending some time pushing through integration tests, and in so doing, I wanted to deploy various versions to a Maven repository and pull them back down.</p>
<p>Creating a Maven repository for SmokejumperIT was pretty simple.</p>
<ol>
<li>Create a space on the internet for the repository which is accessible via public-key-authenticated SCP. In my case, it&#8217;s <a rel="nofollow" target="_blank" href="http://repo.smokejumperit.com">http://repo.smokejumperit.com</a>.</li>
<li>Create a configuration in the Gradle build file for the JARs needed to deploy: <div class="wp_syntax"><div class="code"><pre class="groovy" style="font-family:monospace;">configurations <span style="color:#66cc66;">&#123;</span> deployerJars
<span style="color:#66cc66;">&#125;</span>
&nbsp;
repositories <span style="color:#66cc66;">&#123;</span> mavenRepo urls: <span style="color:#ff0000;">"file://${System.properties['user.home']}/.m2/repository/"</span> mavenCentral<span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">&#41;</span>
<span style="color:#66cc66;">&#125;</span>
dependencies <span style="color:#66cc66;">&#123;</span> deployerJars <span style="color:#ff0000;">'org.apache.maven.wagon:wagon-ssh:1.0-beta-2'</span>
<span style="color:#66cc66;">&#125;</span></pre></div></div> <p><b>Note:</b> The part in the <code>repositories</code> block is in every build file that I have, so I&#8217;m working on a plugin (working title <code>PreconfigPlugin</code>) that will automatically add that in.
</li>
<li>Configure the <code>uploadArchives</code> task. I had it delegate to various <code>System</code> properties that I set when I run the build script. <div class="wp_syntax"><div class="code"><pre class="groovy" style="font-family:monospace;">uploadArchives <span style="color:#66cc66;">&#123;</span> repositories.<span style="color:#006600;">mavenDeployer</span> <span style="color:#66cc66;">&#123;</span> <span style="color:#000000;font-weight:bold;">def</span> repoUser <span style="color:#66cc66;">=</span> <span style="color:#aaaadd;font-weight:bold;">System</span>.<span style="color:#006600;">properties</span><span style="color:#66cc66;">&#91;</span><span style="color:#ff0000;">'sjit.repo.user'</span><span style="color:#66cc66;">&#93;</span> configuration <span style="color:#66cc66;">=</span> configurations.<span style="color:#006600;">deployerJars</span> repository<span style="color:#66cc66;">&#40;</span>url: <span style="color:#ff0000;">"scp://repo.smokejumperit.com/home/$repoUser/repo.smokejumperit.com/"</span><span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&#123;</span> authentication<span style="color:#66cc66;">&#40;</span> userName: repoUser, privateKey: <span style="color:#000000;font-weight:bold;">new</span> <span style="color:#aaaadd;font-weight:bold;">File</span><span style="color:#66cc66;">&#40;</span><span style="color:#aaaadd;font-weight:bold;">System</span>.<span style="color:#006600;">properties</span><span style="color:#66cc66;">&#91;</span><span style="color:#ff0000;">'sjit.repo.keyFile'</span><span style="color:#66cc66;">&#93;</span><span style="color:#66cc66;">&#41;</span>.<span style="color:#006600;">absolutePath</span>, passphrase: <span style="color:#aaaadd;font-weight:bold;">System</span>.<span style="color:#006600;">properties</span><span style="color:#66cc66;">&#91;</span><span style="color:#ff0000;">'sjit.repo.passphrase'</span><span style="color:#66cc66;">&#93;</span> <span style="color:#66cc66;">&#41;</span> pom <span style="color:#66cc66;">&#123;</span> groupId<span style="color:#66cc66;">=</span><span style="color:#ff0000;">'com.smokejumperit'</span> artifactId<span style="color:#66cc66;">=</span><span style="color:#ff0000;">'gradle-plugins'</span> version<span style="color:#66cc66;">=</span><span style="color:#ff0000;">'0.2-SNAPSHOT'</span> <span style="color:#66cc66;">&#125;</span> <span style="color:#66cc66;">&#125;</span> <span style="color:#66cc66;">&#125;</span>
<span style="color:#66cc66;">&#125;</span></pre></div></div> </li>
<li>Run <code>gradle upload</code>.</li>
</ol>
<p>That&#8217;s all it took. Even better, it does all the funky snapshot management on its own: see <a rel="nofollow" target="_blank" href="http://repo.smokejumperit.com/com/smokejumperit/gradle-plugins/0.2-SNAPSHOT/">http://repo.smokejumperit.com/com/smokejumperit/gradle-plugins/0.2-SNAPSHOT/</a> for the beautiful timestamped results!</p>
<p>This is how builds should be: stupid-simple to do the right thing.</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/gradle-maven-repo-snapshots/#comment-37033">November 27, 2009</a>, <a rel="nofollow" target="_blank" href='http://hamletdarcy.blogspot.com' class='url'>Hamlet D'Arcy</a> wrote: I'd like to hear what you think about Gradle being the result of applying Evans-style Domain Driven Design to build systems. Is a strong domain model for enterprise projects really a great benefit?</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on November 27, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/gradle-maven-repo-snapshots/#respond">http://enfranchisedmind.com/blog/posts/gradle-maven-repo-snapshots/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/gradle-maven-repo-snapshots/">http://enfranchisedmind.com/blog/posts/gradle-maven-repo-snapshots/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (87.250.252.241) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/EOPIJeG2RMw" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/gradle-maven-repo-snapshots/</feedburner:origLink></item>
      <item>
         <title>Announcing Gradle-Plugins</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/cJmVHHW5zNc/</link>
         <description>A lot of people know that I have contributed a lot of Grails plugin work, even if my take on [...]</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=2004</guid>
         <pubDate>Wed, 25 Nov 2009 16:16:20 -0800</pubDate>
         <content:encoded><![CDATA[<p>A lot of people know that <a rel="nofollow" target="_blank" href="http://grails.org/plugin/search?q=Robert+Fischer">I have contributed a lot of Grails plugin work</a>, even if <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/open-source-users/">my take on contributing</a> is <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/open-letter-to-burt-beckwith/">somewhat controversial</a>. Well, I&#8217;m continuing on with that approach of plugin contributions, but now for <a rel="nofollow" target="_blank" href="http://gradle.org">Gradle, the world&#8217;s most awesome build system</a>. You can check out the plugins at <a rel="nofollow" target="_blank" href="http://github.com/RobertFischer/gradle-plugins/">http://github.com/RobertFischer/gradle-plugins/</a>. Be sure to scroll down to see the README file with all of its goodness.</p>
<p>Currently, there are just two plugins: one to get at classloaders and one to execute shell commands. I&#8217;ll probably have some JRuby/Cucumber, maybe JAVACC, and almost certainly some conventional development plugins sometime in the future.</p>
<p>Note that I&#8217;m releasing the Gradle plugins under the CC0 (which is a classier form of my beloved <a rel="nofollow" target="_blank" href="http://sam.zoy.org/wtfpl/">WTFPL</a>). Here are the details:
<p><a rel="nofollow" target="_blank" href="http://creativecommons.org/publicdomain/zero/1.0/" style="text-decoration:none;"><img src="http://i.creativecommons.org/l/zero/1.0/88x31.png" border="0" alt="CC0"/></a><br />To the extent possible under law, <a rel="nofollow" target="_blank" href="http://smokejumperit.com/"><span>Robert Fischer</span></a> has waived all copyright and related or neighboring rights to <span>Smokejumper IT Gradle Plugins</span>. This work is published from <span>United States</span>.</p>
<hr /><h2>Comments</h2><ul><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/#comment-37023">November 25, 2009</a>, <a rel="nofollow" target="_blank" href='http://hamletdarcy.blogspot.com' class='url'>Hamlet D'Arcy</a> wrote: great news. Why not just submit the plugins back to the Gradle project?</li><li><a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/#comment-37024">November 25, 2009</a>, <a rel="nofollow" target="_blank" href='http://www.smokejumperit.com' class='url'>Robert Fischer</a> wrote: @Hamlet Is there a way to do that? I wasn't exactly sure how plugins in the Gradle source code worked, but I'd be more than happy for the code to make it into Gradle core.</li></ul><hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on November 25, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/#respond">http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/">http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (87.250.252.241) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/cJmVHHW5zNc" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/announcing-gradle-plugins/</feedburner:origLink></item>
      <item>
         <title>“Holy Crap, That Worked!”: Running JRuby/Cucumber from Gradle</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/QOzJRLHZNQc/</link>
         <description>I&amp;#8217;m working on some code for my book and I&amp;#8217;m trying out Swinger, which is a Cucumber library for Swing. [...]</description>
         <guid isPermaLink="false">http://enfranchisedmind.com/blog/?p=1956</guid>
         <pubDate>Sat, 31 Oct 2009 17:23:52 -0700</pubDate>
         <content:encoded><![CDATA[<p>I&#8217;m working on some code for my book and I&#8217;m trying out <a rel="nofollow" target="_blank" href="http://github.com/demetriusnunes/swinger">Swinger</a>, which is a <a rel="nofollow" target="_blank" href="http://cukes.info/">Cucumber</a> library for Swing. I wanted to integrate it into my build (which is <a rel="nofollow" target="_blank" href="http://gradle.org">Gradle</a>), but was running into issues. The problem is that I was pulling <a rel="nofollow" target="_blank" href="http://kenai.com/projects/jruby-embed">JRuby-Embed</a> from the central Maven repo, which meant that I could only use the JRuby classes by way of Gradle&#8217;s fancy classloader stunts. The issue is that JRuby does some of its own classloader stunts, so there were classloader issues. The issue resulted in error messages that looked like this:</p>
<pre style="font-size:small;">
Caused by: org.jruby.exceptions.RaiseException: library `enumerator' could not be loaded:
java.lang.ClassNotFoundException: org.jruby.libraries.EnumeratorLibrary at (unknown).new(:1) at (unknown).(unknown)(:1)
</pre>
<p>After tracking through <a rel="nofollow" target="_blank" href="http://kenai.com/projects/jruby/sources/main/content/src/org/jruby">the JRuby source code</a>, I found that <a rel="nofollow" target="_blank" href="http://kenai.com/projects/jruby/sources/main/content/src/org/jruby/RubyInstanceConfig.java">RubyInstanceConfig</a> was grabbing the thread context classloader instead of the classloader used to load itself. I don&#8217;t know what that classloader was set to, but resetting it solved the issue.</p>
<p>Here&#8217;s the resulting Gradle script, which at least runs the gem installs and a Cucumber run:</p> <div class="wp_syntax"><div class="code"><pre class="groovy" style="font-family:monospace;"><span style="color:#000000;font-weight:bold;">import</span> <span style="color:#a1a100;">org.jruby.Main</span> <span style="color:#000000;font-weight:bold;">as</span> JRuby
&nbsp;
buildscript <span style="color:#66cc66;">&#123;</span> repositories <span style="color:#66cc66;">&#123;</span> mavenCentral<span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&#125;</span> dependencies <span style="color:#66cc66;">&#123;</span> classpath <span style="color:#ff0000;">"org.jruby.embed:jruby-embed:0.1.2"</span> <span style="color:#66cc66;">&#125;</span>
<span style="color:#66cc66;">&#125;</span>
&nbsp;
task checkGradle <span style="color:#66cc66;">&lt;&lt;</span> <span style="color:#66cc66;">&#123;</span> <span style="color:#993399;">println</span> <span style="color:#ff0000;">"OK"</span>
<span style="color:#66cc66;">&#125;</span>
&nbsp;
task gems <span style="color:#66cc66;">&lt;&lt;</span> <span style="color:#66cc66;">&#123;</span> <span style="color:#000000;font-weight:bold;">def</span> gemsDir <span style="color:#66cc66;">=</span> <span style="color:#ff0000;">"./build/gems"</span> <span style="color:#b1b100;">if</span><span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">!</span><span style="color:#000000;font-weight:bold;">new</span> <span style="color:#aaaadd;font-weight:bold;">File</span><span style="color:#66cc66;">&#40;</span>gemsDir<span style="color:#66cc66;">&#41;</span>.<span style="color:#006600;">exists</span><span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">&#41;</span><span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&#123;</span> runJRuby<span style="color:#66cc66;">&#40;</span><span style="color:#ff0000;">"gem install -i $gemsDir --no-rdoc --no-ri cucumber"</span><span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&#125;</span>
<span style="color:#66cc66;">&#125;</span>
&nbsp;
task runTest<span style="color:#66cc66;">&#40;</span>dependsOn:gems<span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&lt;&lt;</span> <span style="color:#66cc66;">&#123;</span> <span style="color:#000000;font-weight:bold;">def</span> cukeHome <span style="color:#66cc66;">=</span> <span style="color:#000000;font-weight:bold;">new</span> <span style="color:#aaaadd;font-weight:bold;">File</span><span style="color:#66cc66;">&#40;</span><span style="color:#ff0000;">'./build/gems/gems'</span><span style="color:#66cc66;">&#41;</span>.<span style="color:#006600;">listFiles</span><span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">&#41;</span>.<span style="color:#663399;">find</span> <span style="color:#66cc66;">&#123;</span> it.<span style="color:#006600;">name</span>.<span style="color:#006600;">startsWith</span><span style="color:#66cc66;">&#40;</span><span style="color:#ff0000;">'cucumber-'</span><span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&#125;</span> runJRuby<span style="color:#66cc66;">&#40;</span><span style="color:#ff0000;">"$cukeHome/bin/cucumber src/test/features"</span><span style="color:#66cc66;">&#41;</span>
<span style="color:#66cc66;">&#125;</span>
&nbsp;
<span style="color:#000000;font-weight:bold;">def</span> runJRuby<span style="color:#66cc66;">&#40;</span>cmdArg<span style="color:#66cc66;">&#41;</span> <span style="color:#66cc66;">&#123;</span> <span style="color:#aaaadd;font-weight:bold;">Thread</span>.<span style="color:#006600;">currentThread</span><span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">&#41;</span>.<span style="color:#006600;">setContextClassLoader</span><span style="color:#66cc66;">&#40;</span>JRuby.<span style="color:#000000;font-weight:bold;">class</span>.<span style="color:#006600;">classLoader</span><span style="color:#66cc66;">&#41;</span> <span style="color:#993399;">println</span> <span style="color:#ff0000;">"Running JRuby: $cmdArg"</span> JRuby.<span style="color:#006600;">main</span><span style="color:#66cc66;">&#40;</span><span style="color:#ff0000;">"-S $cmdArg"</span>.<span style="color:#006600;">split</span><span style="color:#66cc66;">&#40;</span><span style="color:#66cc66;">&#41;</span><span style="color:#66cc66;">&#41;</span>
<span style="color:#66cc66;">&#125;</span></pre></div></div> <hr />
This post was by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/author/candide/">Robert Fischer</a>, written on October 31, 2009.<br />
Comment on this post: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/jruby-cucumber-gradle/#respond">http://enfranchisedmind.com/blog/posts/jruby-cucumber-gradle/#respond</a><br />
Public Permalink: <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/posts/jruby-cucumber-gradle/">http://enfranchisedmind.com/blog/posts/jruby-cucumber-gradle/</a>
<hr /><a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/"><img alt="Creative Commons License" style="border-width:0;" src="http://i.creativecommons.org/l/by-sa/3.0/us/88x31.png"/></a><br />This article was a post on <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog">the EnfranchisedMind blog</a>. <span>EnfranchisedMind Blog</span> by <a rel="nofollow" target="_blank" href="http://enfranchisedmind.com/blog/">Robert Fischer, Brian Hurt, and Other Authors</a> is licensed under a <a rel="nofollow" target="_blank" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a>.<p style="display:none;">(Digital Fingerprint: bcecb67d74ab248f06f068724220e340 (87.250.252.241) )</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/QOzJRLHZNQc" height="1" width="1"/>]]></content:encoded>
      <feedburner:origLink>http://enfranchisedmind.com/blog/posts/jruby-cucumber-gradle/</feedburner:origLink></item>
      <item>
         <title>What Is “Secure HTTP”/”HTTPS”?</title>
         <link>http://feedproxy.google.com/~r/em-robert/~3/1tcJb1dNY9o/</link>
         <description>Security is an important issue on the internet. When you type something into your computer, it is usually sent across the wireless network and then the internet without any security. This means that anything you type into the internet (e.g. Google searches) is basically public, even if you are typing it into the [...]</description>
         <guid isPermaLink="false">http://graphickarma.com/?p=656</guid>
         <pubDate>Tue, 06 Oct 2009 19:13:41 -0700</pubDate>
         <content:encoded><![CDATA[<p>Security is an important issue on the internet. When you type something into your computer, it is usually sent across the wireless network and then the internet without any security. This means that anything you type into the internet (e.g. Google searches) is basically public, even if you are typing it into the internet from your own private computer.</p>
<p>For most websites, this relationship to their customers is fine. A local restaurant&#8217;s website, for instance, might just display information about the restaurant and maybe a menu. There is no reason this needs to be protected. If the website asks for private information from the user, though, and especially if the website has a concept of &#8220;logging in&#8221;, then some security is necessary.<br />
<span id="more-656"></span><br />
Without security, the information being sent over the line is unprotected. Minimally, this means that anyone on the same internet connection can read all the information going back and forth, including the private information and user name and password. This is true even if the password is masked in password fields. In a worst case scenario, though, someone else would be able to hijack the communication between your server and the user, basically taking over the user&#8217;s identity.</p>
<p>A naive solution would be to use some simple encryption: the server hands the user a key, the user encrypts messages with the key, and then the user sends the messages to the server. This works out okay, except that someone standing between the server and the user could substitute in a second key, thereby hijacking the conversation. This is called a &#8220;Man in the Middle Attack&#8221;.</p>
<p>The solution to this is HTTPS. HTTPS, sometimes called &#8220;Secure HTTP&#8221;, basically creates a network of trust between the server and the user. The server pays to have their identity assured by some known-trustworthy party. The user receives this certification of identity along with the key, so they know they can trust the key. That key then encrypts the information and sends it back. The Man in the Middle Attack doesn&#8217;t work because that certification of identity can&#8217;t be faked, so any attempt to substitute in a second key is caught right away.</p>
<p>This is why you will have to pay a fee to some trusted party (such as VeriSign) if you want HTTPS set up for your server: that fee goes to verifying your identity and creating the certificate. Once you have that, your users will know that they can trust the communication between themselves and your servers to be safe.</p><img src="http://feeds.feedburner.com/~r/em-robert/~4/1tcJb1dNY9o" height="1" width="1"/>]]></content:encoded>
         <category>Domain Names</category>
      <feedburner:origLink>http://graphickarma.com/blog/2009/10/https-secure-http/</feedburner:origLink></item>
   </channel>
</rss><!-- fe6.pipes.sp1.yahoo.com uncompressed/chunked Tue Mar 16 10:20:43 PDT 2010 -->
