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

<channel>
	<title>Innovation On The Run &#187; Java</title>
	<atom:link href="http://www.innovationontherun.com/tag/java/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.innovationontherun.com</link>
	<description>Ruminations about innovation and software by Rob Di Marco</description>
	<lastBuildDate>Sun, 25 Oct 2009 14:44:46 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Creating a Build Number With Ant and Subversion</title>
		<link>http://www.innovationontherun.com/creating-a-build-number-with-ant-and-subversion/</link>
		<comments>http://www.innovationontherun.com/creating-a-build-number-with-ant-and-subversion/#comments</comments>
		<pubDate>Sat, 26 Jan 2008 05:44:25 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/creating-a-build-number-with-ant-and-subversion/</guid>
		<description><![CDATA[I&#8217;m on a hot streak tonight&#8230; Another comon problem that I have had to solve recently is how to attach a build number to files that are being generated out of an Ant build script. We have developed a versioning scheme (inspired by http://geekswithblogs.net/emanish/archive/2006/09/25/92219.aspx) for our releases where our release are named &#60;major&#62;.&#60;minor&#62;.&#60;revision&#62;.&#60;build&#62;. So a [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m on a hot streak tonight&#8230; Another comon problem that I have had to solve recently is how to attach a build number to files that are being generated out of an <a href="http://ant.apache.org">Ant</a> build script.</p>
<p align="left">We have developed a versioning scheme (inspired by http://geekswithblogs.net/emanish/archive/2006/09/25/92219.aspx) for our releases where our release are named &lt;major&gt;.&lt;minor&gt;.&lt;revision&gt;.&lt;build&gt;. So a valid build number might be 1.18.2.1077. This means it belongs to the first major release of the software, the eighteenth minor version, it is the second attempt at a release for this minor version (usually bug fixes), and it is related to the SVN revision number 1077. Any time we are doing a build we are tagging in our Subversion repository to keep the build number tied to the tag. When I build a release, I want my artifacts to look like to look like this: app-1.18.2.1077.ear.</p>
<p align="left">There are a few ways to do this, One way that I considered was to just include a property or Subversion tag in the build.properties file. But I did not want to maintain it and I have always loathed the auto tags that were available in CVS.</p>
<p align="left">My second option was to use the &lt;svn&gt; Ant task. While this will probably work, I have varying degrees of success using the Java SVN library, especially when connecting to Subversion over SSH as we are doing for this application.</p>
<p align="left">So, I decided to go with using the task in conjunction with <em> svn info</em> and <em>svnversion</em> to set the full.build.version property to the current release number.  This assumes that the repository checked out is of the format <em>svn://REPO_NAME/tags/&lt;MAJOR&gt;.&lt;MINOR&gt;.&lt;REVISION&gt;</p>
<pre>
&lt;exec outputproperty=&quot;build.current.revision&quot; executable=&quot;svnversion&quot;&gt;
         &lt;arg line="-n -c" /&gt;
         &lt;redirector&gt;
           &lt;outputfilterchain&gt;
             &lt;tokenfilter&gt;
                 &lt;replaceregex pattern="^[0-9]*:?" replace="" flags="g"/&gt;
             &lt;/tokenfilter&gt;
          &lt;/outputfilterchain&gt;
        &lt;/redirector>
&lt;/exec&gt;
&lt;exec outputproperty=&quot;build.current.version&quot; executable=&quot;svn&quot;&gt;
  &lt;arg line=&quot;info&quot; /&gt;
  &lt;redirector&gt;
  &lt;outputfilterchain&gt;
  &lt;linecontainsregexp&gt;&lt;regexp pattern=&quot;^URL:&quot; /&gt;&lt;/linecontainsregexp&gt;
   &lt;tokenfilter&gt;
     &lt;replaceregex pattern=&quot;.*\/([^\/]+)$&quot; replace=&quot;\1&quot; flags=&quot;g&quot;/&gt;
   &lt;/tokenfilter&gt;
  &lt;/outputfilterchain&gt;
&lt;/redirector&gt;
&lt;/exec&gt;

&lt;property name=&quot;full.build.version&quot; value=&quot;${build.current.version}.${build.current.revision}&quot; /&gt;</pre>
<p>I&#8217;m sure that I could have gotten the revision from the svn info rather than svnversion, saving a command, but I wasn&#8217;t inspired enough to do it.  Maybe when I have more time.</p>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=45&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d45').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d45" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Creating+a+Build+Number+With+Ant+and+Subversion&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F&amp;title=Creating+a+Build+Number+With+Ant+and+Subversion" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fcreating-a-build-number-with-ant-and-subversion%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d45').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d45').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/creating-a-build-number-with-ant-and-subversion/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
		<item>
		<title>Philly JUG Presentation on Using JRuby</title>
		<link>http://www.innovationontherun.com/philly-jug-presentation-on-using-jruby/</link>
		<comments>http://www.innovationontherun.com/philly-jug-presentation-on-using-jruby/#comments</comments>
		<pubDate>Wed, 24 Oct 2007 10:43:45 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/philly-jug-presentation-on-using-jruby/</guid>
		<description><![CDATA[Last night I presented an Introduction to JRuby at the Philadelphia Java Users Group.&#160; My goal was to introduce Java programmers to Ruby and&#160;get them to how features of the language allowed for functionality and code structure that is not possible in Java alone.&#160; While I did talk about Rails at the end, my point [...]]]></description>
			<content:encoded><![CDATA[<p>Last night I presented an Introduction to JRuby at the <a href="http://phillyjug.jsync.com">Philadelphia Java Users Group</a>.&nbsp; My goal was to introduce Java programmers to Ruby and&nbsp;get them to how features of the language allowed for functionality and code structure that is not possible in Java alone.&nbsp; While I did talk about Rails at the end, my point was to get the developers to understand that the meta-programming functionality in Ruby allows for both plugin develeropers and users of Rails to extend and improve the base platform in many interesting ways.
<p>Probably my favorite example was an expansion on a previous blog post about using <a href="/scraping-dynamic-websites-using-jruby-and-htmlunit/">JRuby and HtmlUnit</a>.&nbsp; In the presentation, I created a simple Domain Specific Language on top of the great HtmlUnit library to allow for simple parsing of pages with content in JavaScript.&nbsp; This was a great example of how JRuby can be used to take advantage of both Java and Ruby
<p>The presentation is available at <a href="http://www.innovationontherun.com/presentation-files/Introduction%20to%20JRuby-10-23-2007.pdf">http://www.innovationontherun.com/presentation-files/Introduction%20to%20JRuby-10-23-2007.pdf</a>&nbsp;and the associated source code can be found at <a href="http://www.innovationontherun.com/presentation-files/JRuby-JUG.zip">http://www.innovationontherun.com/presentation-files/JRuby-JUG.zip</a>.&nbsp; If you are looking at the source code, start with the file ABOUT.txt.&nbsp; It describes the prerequisites needed to get the code to run and the order of the listed files follows the order that they were used in the presentation.
<p>If you have questions or comments, feel free to <a href="http://www.innovationontherun.com/contact/">send me an email</a>.</p>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=42&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d42').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d42" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Philly+JUG+Presentation+on+Using+JRuby&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F&amp;title=Philly+JUG+Presentation+on+Using+JRuby" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fphilly-jug-presentation-on-using-jruby%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d42').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d42').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/philly-jug-presentation-on-using-jruby/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Why Ruby&#8217;s Mixins Gives Rails an Advantage over Java Frameworks</title>
		<link>http://www.innovationontherun.com/why-rubys-mixins-gives-rails-an-advantage-over-java-frameworks/</link>
		<comments>http://www.innovationontherun.com/why-rubys-mixins-gives-rails-an-advantage-over-java-frameworks/#comments</comments>
		<pubDate>Wed, 19 Sep 2007 23:57:42 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/why-rubys-mixins-gives-rails-an-advantage-over-java-frameworks/</guid>
		<description><![CDATA[Much has been made over Paul Graham&#8217;s&#160;famous&#160;posting about how Lisp&#160;gave his startup Viaweb an advantage over the competition.&#160; Graham&#8217;s thesis is that there are features in the Lisp language that could be leveraged to make his programming team more productive and better able to respond to customer needs. The idea that a programming language will [...]]]></description>
			<content:encoded><![CDATA[<p>Much has been made over <a href="http://www.paulgraham.com">Paul Graham&#8217;s</a>&nbsp;famous&nbsp;posting about how <a href="http://en.wikipedia.org/wiki/Lisp_programming_language">Lisp</a>&nbsp;<a href="http://www.paulgraham.com/avg.html">gave his startup Viaweb an advantage</a> over the competition.&nbsp; Graham&#8217;s thesis is that there are features in the Lisp language that could be leveraged to make his programming team more productive and better able to respond to customer needs.</p>
<p>The idea that a programming language will make your team more productive is the Holy Grail of software development.&nbsp; Many languages have been promoted as a cure all for productivity (C++ in the 80s, Java in the 90s, Ruby now, Lisp perpetually), and each turns out to have their benefits and weaknesses.&nbsp; But there is no doubt that certain features in languages can lead to leaps in improvements in productivity.&nbsp; For example, having built in garbage collection&nbsp;is a <em>sine qua non </em>for modern development languages.&nbsp; No one can argue (at least no one can argue well) that garbage collection does not improve developer productivity for 99.9% of development efforts.</p>
<h2>What is Mixin?</h2>
<p>Since many readers may not be aware of what a mixin is, I will try to describe it briefly.&nbsp; Ruby is an object-oriented language.&nbsp; With all object-oriented languages, the designers had to decide whether or not to support <a href="http://en.wikipedia.org/wiki/Multiple_inheritance#Debate">multiple inheritance</a>.&nbsp; Perl and C++&nbsp;designers allow for multiple inheritance, Java does not allow for multiple inheritance but does allow for polymorphism through the use of interfaces.&nbsp; Ruby&#8217;s designers&nbsp;opted to not allow multiple inheritance, but to allow for code from one module to be able to be included in another class.</p>
<p>So consider the following code:</p>
<div style="border-right: 1px dotted; border-top: 1px dotted; padding-left: 1em; border-left: 1px dotted; border-bottom: 1px dotted">
<pre>module BarModule
  def hello_world
    puts "Hello World"
  end
end

class BaseClass
  def class_method
    puts "In class method"
  end
end

class Foo &lt; BaseClass
  include BarModule
end

f = Foo.new
f.class_method
f.hello_world
</pre>
</div>
<p>&nbsp;In this example, we are creating a module named <em>BarModule</em>&nbsp;with a <em>hello_world</em> method, a class named <em>BaseClass</em>, and then another class <em>Foo</em> that extends <em>BaseClass</em> and includes <em>BarModule</em>. The class <em>Foo</em> will then have both the methods from <em>BarModule</em> and <em>BaseClass</em>, but it will only <em>BE</em> an instance of <em>BaseClass</em> as that is its only parent. Somewhat different than what a Java developer would do, but it makes sense. Running this file will result in the following output:</p>
<div style="border-right: 1px dotted; border-top: 1px dotted; padding-left: 1em; border-left: 1px dotted; border-bottom: 1px dotted">
<pre>$ ruby foo.rb
In class method
Hello World
$
</pre>
</div>
<p>So that is a basic example of what a mixin is.</p>
<h2>Adding send() into the equation</h2>
<p>Another interesting and powerful thing about Ruby is that all method calls are actually message passing calls.&nbsp; So for example, we could rewrite:</p>
<div style="border-right: 1px dotted; border-top: 1px dotted; padding-left: 1em; border-left: 1px dotted; border-bottom: 1px dotted">
<pre>f = Foo.new
f.class_method
f.hello_world
</pre>
</div>
<p>to</p>
<div style="border-right: 1px dotted; border-top: 1px dotted; padding-left: 1em; border-left: 1px dotted; border-bottom: 1px dotted">
<pre>f = Foo.send(:new)
f.send(:class_method)
f.send(:hello_world)
</pre>
</div>
<p>and the results would be exactly the same! Again a little weird if new to Ruby, but it this language feature can lead to some very interesting and powerful results.</p>
<h2>Combining include and send</h2>
<p>Now let&#8217;s combine these two methods.&nbsp; What if I wanted to take my <em>BarModule</em> and apply it to a class that is not sign, say the ruby base class <em>String</em>.</p>
<div style="border-right: 1px dotted; border-top: 1px dotted; padding-left: 1em; border-left: 1px dotted; border-bottom: 1px dotted">
<pre>String.send(:include, BarModule)
s = "Arbitrary String"
s.hello_world
</pre>
</div>
<p>Running the above code would produce: </p>
<div style="border-right: 1px dotted; border-top: 1px dotted; padding-left: 1em; border-left: 1px dotted; border-bottom: 1px dotted">
<pre>$ ruby include-bar-module-on-string.rb
Hello World
$
</pre>
</div>
<p>That&#8217;s right, at runtime, I was able to add an arbitrary method onto the base <em>String</em> class. That method is now available to any <em>String</em>s that I instantiate within my application. </p>
<h2>The Implication of this Feature on Rails</h2>
<p>Because of this mixin feature, a developer can add arbitrary methods and modify behavior of core classes at runtime.&nbsp; This is amazingly powerful if you are trying to write plugins and extensions to the framework.&nbsp; Because you can add functionality to existing objects, users can install your plugin and start taking advantage of new functionality without having to make changes to the objects that they are instantiating in their application.&nbsp; In frameworks written in other languages, such as Java, plugging in new functionality means that you need to change how your objects are instantiated.&nbsp; This will require code changes and/or potentially configuration changes (if you are using a dependency injection framework like Spring).&nbsp; Hard to develop, hard&nbsp;to maintain, and a pain for plugin developers to support.&nbsp; But because of the mixin feature, Rails plugin developers can customize the base objects and the users of the plugins do not have to change any of their code or configuration logic.&nbsp; A good example of this can be seen in the <a href="http://www.redhillonrails.org/#row_version_migrations">Row Version</a>&nbsp;Rails plugin.&nbsp; This particular plugin puts a <strong>created_at, UPDATED_AT</strong>&nbsp;and a&nbsp;<strong>row_version</strong> on every row inserted into the database.&nbsp; It requires ZERO code change to make this happen.&nbsp; You just install the plugin and go.&nbsp; It works by adding hooks into the <em>ActiveRecord::Base</em> (the base persistence class in Rails) so that when records are saved, the correct information is put in to those fields.&nbsp; A very easy and powerful plugin to install and use.</p>
<h2>Conclusions</h2>
<p>The point to take away from this is not that Ruby on Rails rocks and Java sucks.&nbsp; Far from it.&nbsp; But choosing a framework with lots of extensions that can take care of many of the mundane tasks allows your developers to spend more of their time focused on the problems of the user and not on common problems.&nbsp; The mixin feature of Ruby allows for the development of easy to use but powerful plugins that will be hard for any non-Ruby based framework to compete with.</p>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=41&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d41').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d41" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F&amp;title=Why+Ruby%26%238217%3Bs+Mixins+Gives+Rails+an+Advantage+over+Java+Frameworks" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fwhy-rubys-mixins-gives-rails-an-advantage-over-java-frameworks%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d41').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d41').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/why-rubys-mixins-gives-rails-an-advantage-over-java-frameworks/feed/</wfw:commentRss>
		<slash:comments>22</slash:comments>
		</item>
		<item>
		<title>Presentation on Using the Embedded JBoss Container</title>
		<link>http://www.innovationontherun.com/presentation-on-using-the-embedded-jboss-container/</link>
		<comments>http://www.innovationontherun.com/presentation-on-using-the-embedded-jboss-container/#comments</comments>
		<pubDate>Wed, 19 Sep 2007 02:37:52 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Open Source]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/presentation-on-using-the-embedded-jboss-container/</guid>
		<description><![CDATA[Gave a presentation tonight to the Philly JBoss Users Group about using Embedded JBoss. For the unaware, Embedded JBoss allows a developer to embed much of the functionality of the JBoss application server (EJB, Messaging, JNDI, Security, Transactions) in another application.&#160; A great use for the technology is in the creation of unit tests that [...]]]></description>
			<content:encoded><![CDATA[<p>Gave a presentation tonight to the <a href="http://www.pjbug.com">Philly JBoss Users Group</a> about using <a href="http://wiki.jboss.org/wiki/Wiki.jsp?page=EmbeddedJBoss">Embedded JBoss</a>. </p>
<p>For the unaware, Embedded JBoss allows a developer to embed much of the functionality of the JBoss application server (EJB, Messaging, JNDI, Security, Transactions) in another application.&nbsp; A great use for the technology is in the creation of unit tests that can actually test Session, Entity, and Message Driven Beans.&nbsp; At <a href="http://www.healthmarketscience.com">Health Market Science</a>, we heavily used the Embedded EJB container (a predecessor to Embedded JBoss) connecting to a in-memory Hypersonic DB for improving out unit tests.&nbsp; It made developing and debugging significantly easier and all of the developers loved doing it.&nbsp; I highly encourage any developer that is developing using EJB3, and especially anyone using JBoss, to use the combination of Embedded JBoss.</p>
<p>Full Presentation can be found at <a title="http://www.innovationontherun.com/presentation-files/Intro%20to%20Embedded%20JBoss.pdf" href="http://www.innovationontherun.com/presentation-files/Intro%20to%20Embedded%20JBoss.pdf">http://www.innovationontherun.com/presentation-files/Intro%20to%20Embedded%20JBoss.pdf</a></p>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=40&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d40').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d40" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Presentation+on+Using+the+Embedded+JBoss+Container&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F&amp;title=Presentation+on+Using+the+Embedded+JBoss+Container" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fpresentation-on-using-the-embedded-jboss-container%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d40').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d40').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/presentation-on-using-the-embedded-jboss-container/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Scraping Dynamic Websites Using JRuby and HtmlUnit</title>
		<link>http://www.innovationontherun.com/scraping-dynamic-websites-using-jruby-and-htmlunit/</link>
		<comments>http://www.innovationontherun.com/scraping-dynamic-websites-using-jruby-and-htmlunit/#comments</comments>
		<pubDate>Wed, 05 Sep 2007 21:58:21 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/scraping-dynamic-websites-using-jruby-and-htmlunit/</guid>
		<description><![CDATA[Scraping static web sites to verify functionality or to access data has been around as long as there has been a web (example of scraping of a static web&#160;page with Ruby).&#160; But with the advent of AJAX and other techniques that use JavaScript to dynamically insert HTML into a web page, scraping has gotten more [...]]]></description>
			<content:encoded><![CDATA[<p>Scraping static web sites to verify functionality or to access data has been around as long as there has been a web (example of <a href="http://muharem.wordpress.com/2007/09/04/scrape-the-web-with-ruby/">scraping of a static web&nbsp;page with Ruby</a>).&nbsp; But with the advent of AJAX and other techniques that use JavaScript to dynamically insert HTML into a web page, scraping has gotten more challenging.&nbsp; Most scraping technology does fine when downloading a single HTML page, but cannot easily handle the dynamic content.</p>
<p>With the 1.12 release of <a href="http://htmlunit.sourceforge.net">HtmlUnit</a>, this&nbsp;headless web browser can now support parsing and executing JavaScript.&nbsp; This allows a scraper to access this dynamic content as simply as the scraper accesses static content, and without having to fire up a heavy execution engine like Gecko.</p>
<p><a href="http://jruby.codehaus.org">JRuby</a> is a great technology for easily construct a script that calls into the HtmlUnit functionality without having to deal with all the syntactic sugar that Java requires.</p>
</p>
<h1>Step 0: About The Example Code</h1>
<p>The tar ball, <a href="http://www.innovationontherun.com/jruby-scraper/scraper.tgz">scraper.tgz</a>, contains:</p>
<ul>
<li><a href="http://www.innovationontherun.com/jruby-scraper/scraper.rb ">scraper.rb</a> &#8211; the JRuby script we will be executing.&nbsp; All code discussed in this example comes from there
<li>lib/*.jar &#8211; all of the JAR files needed to run the example
<li>run.sh &#8211; a simple shell script that&nbsp;points JRuby at the lib directory and silences some warning messages</li>
</ul>
<h1>Step 1: Enabling JRuby to Use the Java JAR files</h1>
<table cellspacing="0" cellpadding="0" width="451" border="0" unselectable="on">
<tbody>
<tr>
<td valign="top" width="449">
<pre class="code"># Require Java so we can use the Java libraries
require 'java';

# Get HTML Unit and all of its required libraries
require 'htmlunit-1.13.jar';
require 'commons-httpclient-3.1.jar';
require 'commons-io-1.3.1.jar';
require 'commons-logging-1.1.jar';
require 'commons-lang-2.3.jar'
require 'commons-codec-1.3.jar'
require 'xercesImpl-2.6.2.jar'
require 'xmlParserAPIs-2.6.2.jar'
require 'jaxen-1.1.1.jar'
require 'commons-collections-3.2.jar'
require 'js-1.6R7'
require 'nekohtml-0.9.5.jar'

# Include the Web Client class
include_class 'com.gargoylesoftware.htmlunit.WebClient';</pre>
</td>
</tr>
</tbody>
</table>
<p>In this block, we first use the are telling JRuby to use the JAR files required by HtmlUnit.&nbsp; Some notes:</p>
<ul>
<li>You have to specify every JAR file that HtmlUnit depends upon, even if you are not calling the method directly
<li>All JAR files must be in the LOAD_PATH for JRuby.&nbsp; This is done by -I&lt;DIR_NAME&gt; arguments passed in to JRuby from the command line.
<li>The <em>include_class</em><strong> </strong>is similar to an import statement in Java and puts the WebClient object in scope.</li>
</ul>
<p>At this point, we can now instantiate and use the WebClient class</p>
<h1>Step 2: Parsing a Basic HTML Page</h1>
<p>Before we get into parsing a dynamic page, let&#8217;s take a look at how to parse a simple page.&nbsp; In this example, I am going to parse out information from the Maven 2 Archive for HtmlUnit found at <a title="http://repo1.maven.org/maven2/htmlunit/htmlunit" href="http://repo1.maven.org/maven2/htmlunit/htmlunit">http://repo1.maven.org/maven2/htmlunit/htmlunit</a>.</p>
<table cellspacing="0" cellpadding="0" width="400" border="0" unselectable="on">
<tbody>
<tr>
<td valign="top" width="400">
<pre class="code"># Function for getting a list of all directories
def get_htmlunit_maven_pages
  wc = WebClient.new;

  page = wc.getPage("http://repo1.maven.org/maven2/htmlunit/htmlunit");

  # List the directories...
  page.getByXPath('//img[@alt="[DIR]"]').each do |img|
    a = img.getNextSibling.getNextSibling
    puts 'DIR: ' + a.getHrefAttribute
  end

  # List the files...
  page.getByXPath('//img[@alt="[TXT]"]').each do |img|
    a = img.getNextSibling.getNextSibling
    puts 'FILE: ' + a.getHrefAttribute
  end
end</pre>
</td>
</tr>
</tbody>
</table>
<p>The first step in the method is instantiating a new instance by calling <em>WebClient.new </em>and then download the page using <em>wc.getPage.</em></p>
<p>When requesting a page with a content type of text/html, the getPage call will return an instance of <a href="http://htmlunit.sourceforge.net/apidocs/com/gargoylesoftware/htmlunit/html/HtmlPage.html">HtmlPage</a>, and we can now use XPath expressions and DOM calls to get the URLs for the directories and for files.&nbsp; Very simple to get at the appropriate data.&nbsp; HtmlUnit has a bunch of other methods that you can use to navigate the page, check out the <a href="http://htmlunit.sourceforge.net/apidocs/com/gargoylesoftware/htmlunit/html/HtmlPage.html">source documentation for the HtmlPage</a> object.</p>
<h1>Step 3: Parsing Data Written By JavaScript Functions</h1>
<p>The code behind parsing a HTML page that uses JavaScript to dynamically create content is actually no harder than the previous example.&nbsp; HtmlUnit will detect the script tags in the page you are downloading and execute the appropriate script in line.&nbsp; For an example, I will use my <a href="http://www.innovationontherun.com">blog home page</a> and its inclusion of a JavaScript widget from <a href="http://www.mybloglog.com">MyBlogLog</a>.&nbsp; This script makes a call to MyBlogLog and finds out who the most recent registered users to visit my site have been.&nbsp; In our example, we will parse out these users name and URLs.</p>
<table cellspacing="0" cellpadding="0" width="400" border="0" unselectable="on">
<tbody>
<tr>
<td valign="top" width="400">
<pre class="code"># Function for seeing who the most recent my blog log users were

def search_iotr
  wc = WebClient.new;

  page = wc.getPage("http://www.innovationontherun.com");
  my_blog_log_info = page.getHtmlElementById("MBL_COMM")
  my_blog_log_info.getByXPath('//td[@class="mbl_mem"]').each do |td|
    td.getByXPath('//a').each do |a|
      puts a.asText + ":" + a.getHrefAttribute
    end
  end
end
</pre>
</td>
</tr>
</tbody>
</table>
<p>If you look at the source for this page, you will see a script tag that downloads a JavaScript file from MyBlogLog.com.&nbsp; The downloaded JavaScript will make calls to <em>document.write</em> that will insert an HTML table into the page.&nbsp; The id of the table is MBL_COMM, so our first step is to find that HTML element.&nbsp; Once we have the element, it is a couple of simple XPath expressions to find the anchor tag that contains the recent visitors name and URL.&nbsp; All of the implementation of downloading the data and putting into the HTML page is hidden from us by HtmlUnit so we can easily use DOM to get at the information we are interested in.</p>
<h1>Other Situations Where HtmlUnit Rocks!</h1>
<p>Anytime JavaScript is being used to either enable navigation or modify the HTML document, HtmlUnit can be a great asset in your parsing.&nbsp; This includes:</p>
<ul>
<li>Content from AJAX requests</li>
<li>Situations where JavaScript events are being used to impact behavior.&nbsp; An example would be a page using an onChange handler on a select list to modify form values and/or submit the form.&nbsp; HtmlUnit is very handy for simplifying this interaction.</li>
</ul>
<p>A word of caution, the JavaScript implementation is not fully featured in HtmlUnit, so some sites still may not work.&nbsp; However, the HtmlUnit team is validating the browser against a fair number of popular libraries, so hopefully in future HtmlUnit releases, this will be less of an issue.</p>
<h1>Appendix</h1>
<h2>Prerequisite Information To Run the Example</h2>
<p>Make sure that you have Java installed.&nbsp; I am using Java 1.6, but HtmlUnit and JRuby should support older versions.</p>
<p>Download JRuby from <a title="http://dist.codehaus.org/jruby/jruby-bin-1.0.1.tar.gz" href="http://dist.codehaus.org/jruby/">http://dist.codehaus.org/jruby/</a>&nbsp;and put the jruby executable (found in the bin directory of the downloaded file) in your path.</p>
<p>To verify that Java and jruby are set up correctly, just run jruby from the command line and ask for the version:</p>
<p>
<pre class="code">  &gt; jruby -version
ruby 1.8.5 (2007-08-23 rev 4201) [x86-jruby1.0.1]</pre>
<h2>My Environment Details</h2>
<ul>
<li>JRuby version 1.0.1
<li>HtmlUnit 1.13
<li>Java version 1.6.0_02-b05
<li>Ubuntu 7.0.4</li>
</ul>
<h1>Reference</h1>
<ul>
<li><a href="http://jruby.codehaus.org/">JRuby Home Page</a>
<li><a href="http://htmlunit.sourceforge.net">HtmlUnit Home Page</a>
<li><a href="http://htmlunit.sourceforge.net/apidocs/index.html">HtmlUnit Java Doc</a>
<li><a title="http://www.innovationontherun.com/jruby-scraper/scraper.tgz" href="http://www.innovationontherun.com/jruby-scraper/scraper.tgz">http://www.innovationontherun.com/jruby-scraper/scraper.tgz</a>&nbsp;- The source code for this example</li>
</ul>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=38&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d38').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d38" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F&amp;title=Scraping+Dynamic+Websites+Using+JRuby+and+HtmlUnit" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fscraping-dynamic-websites-using-jruby-and-htmlunit%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d38').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d38').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/scraping-dynamic-websites-using-jruby-and-htmlunit/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Betting on JavaFX Is a Bad Bet Indeed</title>
		<link>http://www.innovationontherun.com/betting-on-javafx-is-a-bad-bet-indeed/</link>
		<comments>http://www.innovationontherun.com/betting-on-javafx-is-a-bad-bet-indeed/#comments</comments>
		<pubDate>Wed, 05 Sep 2007 16:44:25 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Technology Business]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/betting-on-javafx-is-a-bad-bet-indeed/</guid>
		<description><![CDATA[In the last few months, Adobe, Sun, and Microsoft have all had major announcements around their platforms for developing rich Internet applications (RIA).&#160; Adobe, the current market leader in the RIA space with their combination of Flash and Flex, has recently been promoting the Air product that will allow Flex applications to hook into the [...]]]></description>
			<content:encoded><![CDATA[<p>In the last few months, Adobe, Sun, and Microsoft have all had major announcements around their platforms for developing rich Internet applications (RIA).&nbsp; Adobe, the current market leader in the RIA space with their combination of <a href="http://www.adobe.com/products/flash/">Flash</a> and <a href="http://www.adobe.com/products/flex/">Flex</a>, has recently been promoting the <a href="http://labs.adobe.com/technologies/air/">Air</a> product that will allow Flex applications to hook into the desktop.&nbsp; Microsoft has announced their <a href="http://silverlight.net/">Silverlight</a> technology with a focus on integration with scripting and .NET languages and a strong focus on high quality video and audio experience.&nbsp; Right after the Silverlight announcement, in what seemed like a knee jerk press release, Sun announced the <a href="http://java.sun.com/javafx/">Java FX</a>&nbsp;technology to ostensibly compete in the space.&nbsp; There are two motivators that are really driving interest in these technologies:&nbsp;better media (e.g. audio and video) experiences and better online/offline experiences.&nbsp; Adobe and Microsoft&nbsp;get this and these drivers have been at the forefront of their offerings.&nbsp; Sun hasn&#8217;t gotten the message.</p>
<p>Flash has been around for a long time and is installed and active on almost every browser, it seems most of the major video sites (e.g. YouTube) are currently using Flash as their RIA platform and the Flash 9 player has some new video/audio codec supports as well as support for ActionScript 3 that meets the ECMAScript specification (basically JavaScript).&nbsp; Flash/Flex are mature, have solid tools, great documentation, a vibrant community and a huge installation base.&nbsp; Flash/Flex has <a href="http://www.marketingterms.com/dictionary/first_mover_advantage/">first mover advantage</a> in the space.</p>
<p>Silverlight has just released their 1.0 and has gotten a ton of press.&nbsp; From the development side, the combination of JavaScript and XML to create applications feels a lot like building applications with Flex.&nbsp; Silverlight has also been designed to hook into .NET languages including <a href="http://www.iunknown.com/2007/07/a-first-look-at.html">IronRuby</a> and <a href="http://www.codeplex.com/Wiki/View.aspx?ProjectName=IronPython">IronPython</a> and is really focusing on high quality audio and video experience.&nbsp; For some cool examples of the technology&nbsp;check out a visual search engine, <a href="http://www.tafiti.com/">tafiti.com</a>&nbsp;or the live streaming television broadcasting application <a href="http://www.livestation.com">LiveStation</a>.&nbsp; There is cross-browser and cross-platform support for the toolkit.&nbsp; Not a huge community or install base just yet, but the technology is easy to install (about 4 MB download), easy to develop with,&nbsp;produces a fast and clean user experience, and the easy hook in to .NET languages plus its inevitable preloading into base Windows installs means that these communities will build up fast.</p>
<p>JavaFX is basically a nicer way to write applets.&nbsp; There is no focus on offline applications, no focus on media, and a small effort on reducing download sizes.&nbsp; Really nothing very interesting or new from what Java developers have had before.</p>
<p>It seems no one at Sun has ever read <a href="http://www.amazon.com/gp/product/0887306667?ie=UTF8&amp;tag=innoontherun-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0887306667">The 22 Immutable Laws of Marketing</a>[1].&nbsp; Let&#8217;s look at how many of the marketing laws Sun is violating.</p>
<ul>
<li>Law of Leadership &#8211; Being the first to market.&nbsp; Sun actually had an opportunity 10 years ago when applets were starting to be built.&nbsp; But while they may have been first to market for embedded applications in a browser, they let Adobe Flash be the first into the easy to install browser plugin for media applications.
<li>Law of Mind and Law of Perception &#8211; Java GUI applications are thought of as being big, slow, and ugly.&nbsp; By including the term Java in the JavaFX name, people will clearly associate JavaFX applications with those terms as well.&nbsp; Sun should rebrand.
<li>Law of the Ladder/Law of Duality&nbsp;-&nbsp;It is very hard to&nbsp;change market position.&nbsp; And if you are not one of the&nbsp;top two players in a market, you need to find a new market.&nbsp; JavaFX will not be in the top two, they need a new market.
<li>Law of Line Extension &#8211; Another problem with Java,&nbsp;the brand is so&nbsp;generic and means so many things that you don&#8217;t know what it is.&nbsp; Java ME, Java SE, Java EE, JavaFX.&nbsp; They all leverage the Java brand, but are all wildly different products.&nbsp; (Sidenote, Sun&#8217;s changing their NASDAQ stock ticker symbol to JAVA continues these violations)
<li>Law of Resources &#8211; Adobe is going around with their <a href="http://onair.adobe.com/?sdid=BDBZJ">Adobe AIR tour</a>.&nbsp; Microsoft is partnering with a bunch of big media players (e.g. check out <a title="http://silverlight.net/Showcase/" href="http://silverlight.net/Showcase/">http://silverlight.net/Showcase/</a>&nbsp;for samples for WWE, CBS, MLB) to work with Silverlight.&nbsp; Sun spent some money on a press release.</li>
</ul>
<p>For JavaFX to be a success, for their to be a community, I would recommend the following:</p>
<ul>
<li>Figure out what market segment you are solving problems for.&nbsp; Do you want to be in the consumer RIA space or should the focus be on RIA applications developed within corporate intranets?&nbsp; Where Adobe and Microsoft are focusing on the consumer space (explaining the drivers of media and online/offline play), perhaps Sun could focus on a different problem space with different needs.
<li>Stop with every name starting with the Java brand!&nbsp; Get some differentiations with product names so people know what they are talking about.
<li>Come up with a real roadmap for the technology and let the development community know it is a&nbsp;core part of Sun&#8217;s development path, not a one off project.</li>
</ul>
<p>[1] EVERYONE should own this book.&nbsp; It&#8217;s $10, will take an hour to read, and will change your view of how you look at your company and business.</p>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=37&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d37').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d37" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F&amp;title=Betting+on+JavaFX+Is+a+Bad+Bet+Indeed" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fbetting-on-javafx-is-a-bad-bet-indeed%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d37').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d37').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/betting-on-javafx-is-a-bad-bet-indeed/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Java Kernel In Java 1.6 Update 4.  When Can I Try It?</title>
		<link>http://www.innovationontherun.com/java-kernel-in-java-16-update-4-when-can-i-try-it/</link>
		<comments>http://www.innovationontherun.com/java-kernel-in-java-16-update-4-when-can-i-try-it/#comments</comments>
		<pubDate>Tue, 21 Aug 2007 20:40:13 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/java-kernel-in-java-16-update-4-when-can-i-try-it/</guid>
		<description><![CDATA[A recent blog post let&#8217;s the world know that the Java Kernel will be a part of JDK 6 Update 4.&#160; There is not a lot of information around what this means outside of&#160;Ethan Nicholas&#8217;s blog entry in May&#160;and some of his earlier posts describing the intent project and the official announcement&#160;about&#160;the project.&#160; Seems like [...]]]></description>
			<content:encoded><![CDATA[<p>A recent blog post let&#8217;s the world know that the <a href="http://weblogs.java.net/blog/forax/archive/2007/08/java_kernel_in.html">Java Kernel will be a part of JDK 6 Update 4</a>.&nbsp; There is not a lot of information around what this means outside of&nbsp;<a href="http://weblogs.java.net/blog/enicholas/archive/2007/05/java_kernel_unm.html">Ethan Nicholas&#8217;s blog entry in May</a>&nbsp;and some of his earlier posts <a href="http://weblogs.java.net/blog/enicholas/archive/2006/09/java_browser_ed.html">describing the intent project</a> and the official <a href="http://weblogs.java.net/blog/enicholas/archive/2007/05/announcing_the.html">announcement&nbsp;about&nbsp;the project</a>.&nbsp; Seems like a cool idea to shrink the default download size of the JRE, but it is hard to understand the impact of this.</p>
<p>This really irritates the hell out of me.&nbsp; How can there not be an easy to find example and demonstration of this functionality?&nbsp; Maybe I am just blind, but I could not find anything from Ethan&#8217;s blog pages or by searching Google where I could see examples and understand how the implementation works.&nbsp; Will there be tight coupling with <a href="http://www.sun.com/software/javafx/index.jsp">JavaFX</a>?&nbsp; How significantly will it reduce start up times.&nbsp; Is this really such a minor feature it should be released in a JDK update rather than JDK 7?&nbsp; This announcement seems to create more questions than it answers.</p>
<p>Some other discussion pages:</p>
<ul>
<li><a title="http://www.ddj.com/blog/javablog/archives/2007/05/the_java_kernel.html" href="http://www.ddj.com/blog/javablog/archives/2007/05/the_java_kernel.html"><a title="http://forums.java.net/jive/thread.jspa?forumID=25&amp;threadID=22378" href="http://forums.java.net/jive/thread.jspa?forumID=25&amp;threadID=22378">http://forums.java.net/jive/thread.jspa?forumID=25&amp;threadID=22378</a></a></li>
<li><a href="http://www.ddj.com/blog/javablog/archives/2007/05/the_java_kernel.html">http://www.ddj.com/blog/javablog/archives/2007/05/the_java_kernel.html</a></li>
</ul>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=32&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d32').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d32" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F&amp;title=Java+Kernel+In+Java+1.6+Update+4.++When+Can+I+Try+It%3F" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fjava-kernel-in-java-16-update-4-when-can-i-try-it%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d32').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d32').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/java-kernel-in-java-16-update-4-when-can-i-try-it/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Debugging JavaScript Executing in Java with HtmlUnit</title>
		<link>http://www.innovationontherun.com/debugging-javascript-executing-in-java-with-htmlunit/</link>
		<comments>http://www.innovationontherun.com/debugging-javascript-executing-in-java-with-htmlunit/#comments</comments>
		<pubDate>Mon, 20 Aug 2007 21:05:54 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Open Source]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/debugging-javascript-executing-in-java-with-htmlunit/</guid>
		<description><![CDATA[For the past few days, I have been doing a little work with embedded JavaScript within the HtmlUnit&#160;project.&#160; HtmlUnit is a really cool project that is a headless web browser written in Java that is really useful if you are trying to do automated testing or web scraping and want to simulate how a real [...]]]></description>
			<content:encoded><![CDATA[<p>For the past few days, I have been doing a little work with embedded JavaScript within the <a href="http://htmlunit.sourceforge.net">HtmlUnit</a>&nbsp;project.&nbsp; HtmlUnit is a really cool project that is a headless web browser written in Java that is really useful if you are trying to do automated testing or web scraping and want to simulate how a real browser works.&nbsp; One of the neat features is that it supports JavaScript execution within the HTML page so scripts that modify the DOM can be supported.&nbsp; One site that I was trying to automate a script for uses the <a href="http://developer.yahoo.com/yui/">YUI</a> JavaScript libraries and I was having some problems with HtmlUnit, so I volunteered to have a shot at trying to get all of the unit tests to pass.</p>
<p>The hardest part of the development has been trying to debug why the hell all of the scripts have been failing.&nbsp; Most of the problems seem to fall into one or more of a few categories:</p>
<ul>
<li>Hacks in the YUI libraries to deal with the fact that IE and Firefox both operate differently and NEITHER is fully compliant with the DOM specification.&nbsp; That has made for lots of fun times.&nbsp; I have found a certain irony that I am cursing the Yahoo developers for the hacks that they wrote while probably cursing </li>
<li>Bugs with the <a href="http://developer.mozilla.org/en/docs/Rhino">Rhino JavaScript</a> libraries.&nbsp; For example, I could not even start the YUI tests until I upgraded to 1.6R6.&nbsp; Also, I&nbsp;think I found a&nbsp;subtle bug&nbsp;that is causing one of the unit tests to fail related to the&nbsp;<em>for&#8230;in</em> syntax, but it has been a bitch to reproduce.</li>
<li>No integrated debugging of the JavaScript code.&nbsp; The only way I can diagnose what is really breaking is by liberal use of the alert() method and then a review of the output.&nbsp; Hopefully this will change in <a href="http://developer.mozilla.org/en/docs/New_in_Rhino_1.7R1">Rhino 1.7</a>.&nbsp; Huge problem.</li>
<li>Unhelpful error messages.&nbsp; For example, I was getting a NullPointerException being thrown from SOMEWHERE in a script, but the stack trace was lost when it was transformed to a ScriptException.&nbsp; The only way I was able to debug the problem was to put a breakpoint on the constructor for NullPointerException and then look at the runtime stack when it was thrown, then grep through the Yahoo JavaScript to try to figure out where the problem could possibly be.</li>
</ul>
<p>So if you ever having to work with the implementation</p>
<ul>
<li>Make sure you are using a good IDE with a debugger.&nbsp; I cannot stress this enough.&nbsp; I have had to put breakpoints all over the damn place.&nbsp; And integrate as much of the source code around as you can and integrate it with the debugger.</li>
<li>If you are using Java 6, I would STRONGLY RECOMMEND NOT USING THE DEFAULT SCRIPTING IMPLEMENTATIONS!!!&nbsp; I have now worked with both the JRuby and JavaScript libraries.&nbsp; It is way easier to upgrade versions of your libraries to work around bugs if you are using the standalone implementations rather than the versions built into the JVMs.&nbsp; By the way, how much fun will it be when a later version of Java comes out with new scripting libraries that I am sure will not be 100% backwards compatible.</li>
<li>Take Mozilla, MSDN, and especially W3C reference documents with a grain of salt.&nbsp; They may not fully describe the behavior that you are seeing in the browser.</li>
</ul>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=31&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d31').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d31" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F&amp;title=Debugging+JavaScript+Executing+in+Java+with+HtmlUnit" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fdebugging-javascript-executing-in-java-with-htmlunit%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d31').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d31').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/debugging-javascript-executing-in-java-with-htmlunit/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Compilation Struggles with Java 6 ScriptEngine, JavaScript, and Maven</title>
		<link>http://www.innovationontherun.com/compilation-struggles-with-java-6-scriptengine-javascript-and-maven/</link>
		<comments>http://www.innovationontherun.com/compilation-struggles-with-java-6-scriptengine-javascript-and-maven/#comments</comments>
		<pubDate>Wed, 08 Aug 2007 04:13:33 +0000</pubDate>
		<dc:creator>Rob Di Marco</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.innovationontherun.com/compilation-struggles-with-java-6-scriptengine-javascript-and-maven/</guid>
		<description><![CDATA[One of the projects I am currently on is to create a Java based headless browser that I can easily control programmatically.&#160; I have wanted this for a couple of reasons over the years, one for navigating websites when trying to scrape information and secondly for use in automated functional testing.&#160; I love the Selenium [...]]]></description>
			<content:encoded><![CDATA[<p>One of the projects I am currently on is to create a Java based headless browser that I can easily control programmatically.&nbsp; I have wanted this for a couple of reasons over the years, one for navigating websites when trying to scrape information and secondly for use in automated functional testing.&nbsp; I love the <a href="http://www.openqa.org/selenium-ide/">Selenium IDE</a>&nbsp;but I find that it is impossible to automate your Selenium scripts into an automated build because it requires an actual browser (e.g. Firefox, Internet Explorer, etc.) to be started and executed each time.&nbsp; So I want a headless browser that will do navigation, manage the DOM model of the page, and execute JavaScript to handle AJAX calls.&nbsp; (SIDENOTE:&nbsp; I am planning on open sourcing this and am waiting for approval from SourceForge to move the code out there).</p>
<p>To support JavaScript, I wanted to just use the <a href="http://java.sun.com/javase/6/docs/api/javax/script/ScriptEngineManager.html">ScriptEngineManager</a>&nbsp;found in Java 6 to execute JavaScript.&nbsp; Well, one problem that I found is that it is a real pain to get at objects that have been created in an executed script.&nbsp; Consider the following JavaScript example:</p>
<blockquote><p><strong>sample.js</strong></p>
<p>var foo = ["a","b"];</p>
</blockquote>
<p>To execute that in Java 6, you would do the following:</p>
<p>ScriptEngineManager sm = new ScriptEngineManager();<br />ScriptEngine e = sm.getEngineByExtension(&#8220;js&#8221;); </p>
<p>String script = readFromFile(&#8220;sample.js&#8221;);</p>
<p>e.eval(script);</p>
<p>OK, so far so good.&nbsp; Now let&#8217;s say you want to retrieve the value of&nbsp;<em>foo </em>from the ScriptEngine environment and iterate over the values.&nbsp; The ScriptEngine class has a <a href="http://java.sun.com/javase/6/docs/api/javax/script/ScriptEngine.html#get(java.lang.String)">get</a> method, however, this returns an Object of type <em>sun.org.mozilla.javascript.internal.NativeArray</em>, not a Java Array.&nbsp; So to access values, you will need to cast the Object to a NativeArray.&nbsp; Then, as you iterate the array, you might have to cast each value to a NativeObject as the get method on NativeArray only returns an object.</p>
<blockquote><p>NativeArray a = (<em>sun.org.mozilla.javascript.internal.NativeArray</em>)e.get(&#8220;foo&#8221;);</p>
<p>for (int i = 0; i &lt; a.getLength(); i++) {</p>
<p>&nbsp; System.out.println(a.get(i, a));</p>
<p>}</p>
</blockquote>
<p>Now your code is relying on a Sun internal class and not a base JDK class.&nbsp; The appropriate classes exist in the $JAVA_HOME/lib/rt.jar file.&nbsp; Unfortunately, this jar&nbsp;file is NOT&nbsp;used by default&nbsp;when running javac.&nbsp; So to get my code to compile, I had to use the rt.jar in my bootclasspath.&nbsp;&nbsp;Since I&nbsp;am using <a href="http://maven.apache.org">Maven 2.0</a>&nbsp;as my build system, I had to add the following to the pom.xml where I am defining my compiler</p>
<blockquote><p>&lt;plugin&gt;<br />&nbsp; &lt;artifactId&gt;maven-compiler-plugin&lt;/artifactId&gt;<br />&nbsp; &lt;configuration&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;source&gt;1.6&lt;/source&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;target&gt;1.6&lt;/target&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;compilerArguments&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;verbose /&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;bootclasspath&gt;${java.home}/lib/rt.jar&lt;/bootclasspath&gt;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/compilerArguments&gt;<br />&nbsp; &lt;/configuration&gt;<br />&lt;/plugin&gt;</p>
</blockquote>
<p>This put the rt.jar into the bootclasspath when building and allowed my code to compile.&nbsp; What I had hoped would be a simple task turned out to be a real ordeal.</p>
<p>Using the sun.org.mozilla.javascript.internal classes is very, very&nbsp;ugly and has the added distraction that it is hard to build and will be hard to maintain.&nbsp; I do not see a way around the problem and I have found&nbsp;other people having <a href="http://www.mcqueeney.com/roller/page/tom?entry=returning_from_ruby_or_javascript">similar problems working with the scripting API</a>.&nbsp; If anyone has a better approach, I am all ears.</p>
<img src="http://www.innovationontherun.com/?ak_action=api_record_view&id=29&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a title="Click me to see the sites." href="#" onclick="$$('div.d29').each( function(e) { e.visualEffect('slide_down',{duration:2.5}) }); return false;"><strong><em>Bookmark to:</em></strong></a>
<br />
<div class="d29" style="overflow:hidden">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven&amp;url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.squidoo.com/lensmaster/bookmark?http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F" rel="nofollow" title="Add to&nbsp;Squidoo"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/squidoo.png" title="Add to&nbsp;Squidoo" alt="Add to&nbsp;Squidoo" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F&amp;title=Compilation+Struggles+with+Java+6+ScriptEngine%2C+JavaScript%2C+and+Maven" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.innovationontherun.com%2Fcompilation-struggles-with-java-6-scriptengine-javascript-and-maven%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.innovationontherun.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<br />
<a style="font-size:90%;text-align: right; " title="Click me to hide the sites." href="#" onclick="$$('div.d29').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); return false;">Hide Sites</a>
</div>
</div>
<!-- Social Bookmarks END -->
<script type="text/javascript">$$('div.d29').each( function(e) { e.visualEffect('slide_up',{duration:0.5}) }); </script>]]></content:encoded>
			<wfw:commentRss>http://www.innovationontherun.com/compilation-struggles-with-java-6-scriptengine-javascript-and-maven/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
