<?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:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Fabio Kung</title>
	<atom:link href="http://fabiokung.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://fabiokung.com</link>
	<description>better than writing good code is deleting code</description>
	<pubDate>Thu, 23 Oct 2008 19:03:56 +0000</pubDate>
	<generator>http://wordpress.org/?v=MU</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>EJB 4: the Future</title>
		<link>http://fabiokung.com/2008/10/08/ejb-4-the-future/</link>
		<comments>http://fabiokung.com/2008/10/08/ejb-4-the-future/#comments</comments>
		<pubDate>Thu, 09 Oct 2008 02:33:04 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[di]]></category>

		<category><![CDATA[ioc]]></category>

		<category><![CDATA[java]]></category>

		<category><![CDATA[future container ioc di ejb]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=84</guid>
		<description><![CDATA[Reading an article from Reza Rahman in TSS about what is new in EJB 3.1, I could predict the future. Here is a code snippet from the article:


EJBContainer container = EJBContainerFactory.createEJBContainer();
Context context = container.getContext();
PlaceBid placeBid = (PlaceBid) context.lookup(&#34;java:global/action-bazaar/PlaceBid&#34;);
placeBid.addBid(new Bid(&#34;rrahman&#34;, 10059, 200.50));
container.close();

Yes, PicoContainer will be standardized as EJB 4.0!
How long is going to take to people [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Reading an article from <a href="http://www.theserverside.com/tt/articles/article.tss?l=NewFeaturesinEJB31-Part5">Reza Rahman in TSS</a> about what is new in EJB 3.1, I could predict the future. Here is a code snippet from the article:</p>
<pre name="code" class="java">

EJBContainer container = EJBContainerFactory.createEJBContainer();
Context context = container.getContext();
PlaceBid placeBid = (PlaceBid) context.lookup(&quot;java:global/action-bazaar/PlaceBid&quot;);
placeBid.addBid(new Bid(&quot;rrahman&quot;, 10059, 200.50));
container.close();
</pre>
<p>Yes, <a href="http://www.picocontainer.org/">PicoContainer</a> will be standardized as <strong>EJB 4.0</strong>!</p>
<p>How long is going to take to people learn that <strong>less is more</strong>?</p>
<p style="font-size:.5em;color:#888;">This is obviously a joke. It isn&#8217;t really true.</p>
Posted in di, ioc, java&nbsp;&nbsp;&nbsp;Tagged: future container ioc di ejb&nbsp;&nbsp;&nbsp;<a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/84/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/84/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/84/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/84/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/84/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/84/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/84/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/84/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/84/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/84/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=84&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/10/08/ejb-4-the-future/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>
	</item>
		<item>
		<title>JRuby, sharing objects across multiple runtimes. JMagLev?</title>
		<link>http://fabiokung.com/2008/10/08/jruby-sharing-objects-across-multiple-runtimes-jmaglev/</link>
		<comments>http://fabiokung.com/2008/10/08/jruby-sharing-objects-across-multiple-runtimes-jmaglev/#comments</comments>
		<pubDate>Wed, 08 Oct 2008 09:39:31 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[java]]></category>

		<category><![CDATA[jruby]]></category>

		<category><![CDATA[maglev]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[terracotta]]></category>

		<category><![CDATA[jruby terracotta nailgun screencast maglev gemstone mul]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=72</guid>
		<description><![CDATA[MagLev was a show from the last RailsConf (2008). Presentation and demos of the product are really impressive.
Recently, Brian Takita asked in the JRuby mailing list:
JRuby + TerraCotta == Maglev?
What an idea! In the last few days I&#8217;ve tried to make something useful and I&#8217;m happy to have something to show.
The first demo runs with [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>MagLev was a show from the last RailsConf (2008). Presentation and demos of the product are <a href="http://www.vimeo.com/1147409">really impressive</a>.</p>
<p>Recently, <a href="http://www.workingwithrails.com/person/8888-brian-takita">Brian Takita</a> asked in the <a href="http://archive.hausfoundation.org/lists/org.codehaus.jruby.dev/msg/1d7ddd110809291539t213f56c1s5ef79d7755976c5f@mail.gmail.com">JRuby mailing list</a>:</p>
<blockquote><p>JRuby + TerraCotta == Maglev?</p></blockquote>
<p>What an idea! In the last few days I&#8217;ve tried to make something useful and I&#8217;m happy to have something to show.</p>
<div id="attachment_78" class="wp-caption aligncenter" style="width: 333px"><a href="http://blog.caelum.com.br/video/jruby/fabiokung-jmaglev.swf" target="_blank"><img src="http://fabiokung.files.wordpress.com/2008/10/jmaglev-demo.png?w=323&#038;h=373" alt="JRuby + Nailgun and JRuby + Terracotta" title="JRuby + Nailgun and JRuby + Terracotta" width="323" height="373" class="size-full wp-image-78" /></a><p class="wp-caption-text">Screencast: Reproducing Avi Bryant's Demo with JRuby + Nailgun and JRuby + Terracotta. (5 min)</p></div>
<p>The first demo runs with Nailgun. The basic idea is to share a single Java VM across all clients, so they can share some objects. The second is much more complete, as its clients have their own Java VM. There are many true interpreters running, and they are sharing objects through <a href="http://www.terracotta.org/">Terracotta</a>. Terracotta is responsible for sharing memory in Java VM clusters and, despite of its slow startup, has much more to offer. The shared objects (hats and rabbits) could be automatically persisted by Terracotta, as MagLev also does.</p>
<p>I&#8217;ve patched JRuby and configured Terracotta to make demos run. I&#8217;ll upload the patches and configuration somewhere, ASAP.</p>
<p>Working on JRuby to make it run multiple runtimes (VMs) at the same time is being really fun!</p>
Posted in java, jruby, maglev, ruby, terracotta&nbsp;&nbsp;&nbsp;Tagged: jruby terracotta nailgun screencast maglev gemstone mul&nbsp;&nbsp;&nbsp;<a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/72/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=72&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/10/08/jruby-sharing-objects-across-multiple-runtimes-jmaglev/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>

		<media:content url="http://fabiokung.files.wordpress.com/2008/10/jmaglev-demo.png" medium="image">
			<media:title type="html">JRuby + Nailgun and JRuby + Terracotta</media:title>
		</media:content>
	</item>
		<item>
		<title>Jetty installed base growing</title>
		<link>http://fabiokung.com/2008/09/02/jetty-installed-base-growing/</link>
		<comments>http://fabiokung.com/2008/09/02/jetty-installed-base-growing/#comments</comments>
		<pubDate>Tue, 02 Sep 2008 17:38:24 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=67</guid>
		<description><![CDATA[I&#8217;m happy to know that Jetty Web Server Closes Gap on Tomcat. From the article:
Jetty web server statistics reach 80% of Apache Tomcat
Great!
       ]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>I&#8217;m happy to know that <a title="from Reuters" href="http://www.reuters.com/article/pressRelease/idUS205622+21-May-2008+BW20080521">Jetty Web Server Closes Gap on Tomcat</a>. From the article:</p>
<blockquote><p>Jetty web server statistics reach 80% of Apache Tomcat</p></blockquote>
<p>Great!</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/67/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/67/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/67/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=67&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/09/02/jetty-installed-base-growing/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>
	</item>
		<item>
		<title>I&#8217;m a Certified Ruby Programmer Silver</title>
		<link>http://fabiokung.com/2008/08/19/im-a-certified-ruby-programmer-silver/</link>
		<comments>http://fabiokung.com/2008/08/19/im-a-certified-ruby-programmer-silver/#comments</comments>
		<pubDate>Tue, 19 Aug 2008 19:14:53 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[ruby]]></category>

		<category><![CDATA[certification ruby]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=50</guid>
		<description><![CDATA[I&#8217;ve just passed the certification exam from Ruby Association. I&#8217;m not allowed to talk much about the test itself, but I leave my warning here: be prepared.
I was surprised, when I found it wasn&#8217;t an easy exam. I haven&#8217;t studied anything, as I&#8217;m working with Ruby everyday. But I should. Unfortunately, the test requires you [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>I&#8217;ve just passed the certification exam from <a title="Ruby Association" href="http://www.ruby-assn.org/">Ruby Association</a>. I&#8217;m not allowed to talk much about the test itself, but I leave my warning here: <strong>be prepared.</strong></p>
<div id="attachment_59" class="wp-caption aligncenter" style="width: 254px"><a href="http://fabiokung.files.wordpress.com/2008/08/ruby-logo-r.png"><img class="size-medium wp-image-59" src="http://fabiokung.files.wordpress.com/2008/08/ruby-logo-r.png?w=244&#038;h=300" alt="Ruby Programming Language" width="244" height="300" /></a><p class="wp-caption-text">Copyright (C) 2008 Ruby Association LLC</p></div>
<p>I was surprised, when I found it wasn&#8217;t an easy exam. I haven&#8217;t studied anything, as I&#8217;m working with Ruby everyday. But I should. Unfortunately, the test requires you to memorize many methods from core classes.</p>
<p><strong>Learn</strong> the <a title="Ruby Core Documentation" href="http://ruby-doc.org/core/">Core API</a>, mainly the <a href="http://ruby-doc.org/core/classes/Array.html">Array</a>, <a href="http://ruby-doc.org/core/classes/Hash.html"><strong>Hash</strong></a>, <a href="http://ruby-doc.org/core/classes/String.html">String</a>, <a href="http://ruby-doc.org/core/classes/Fixnum.html">Fixnum</a>, <a href="http://ruby-doc.org/core/classes/Float.html">Float</a>, <a href="http://ruby-doc.org/core/classes/Object.html">Object</a>, <a href="http://ruby-doc.org/core/classes/Kernel.html">Kernel</a>, <a href="http://ruby-doc.org/core/classes/Time.html">Time</a> and <a href="http://ruby-doc.org/core/classes/File.html">File</a> classes. Study until you memorize their methods. There are many questions about Hashes, Strings and Arrays. Caution with methods that modify the objects itself and methods that don&#8217;t (mutable vs immutable).</p>
<p>Also, be sure that you have a good understanding of Ruby Regular Expressions.</p>
<p>It would be great if the certification had more questions about OO in Ruby, Strings vs Symbols, less API memorization, blocks being the functional guys, operator overloading, modules as mixins, Test::Unit, threads, duck typing, dynamic typing, &#8230;</p>
<p>I haven&#8217;t seen <strong>any</strong> question about polymorphism! Shame.</p>
<p><em>Just to be clear</em>, I don&#8217;t care that much for certifications. There are many people discussing if certifications are good or not (at least here in Brazil). I won&#8217;t discuss it here. My decision to be certified was made, because I teach Ruby classes and, at least here in Brazil, certifications are important to instructors.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/50/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/50/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/50/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/50/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/50/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=50&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/08/19/im-a-certified-ruby-programmer-silver/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>

		<media:content url="http://fabiokung.files.wordpress.com/2008/08/ruby-logo-r.png?w=244" medium="image">
			<media:title type="html">Ruby Programming Language</media:title>
		</media:content>
	</item>
		<item>
		<title>Revising my opinion about Spring Framework</title>
		<link>http://fabiokung.com/2008/07/26/revising-my-opinion-about-spring-framework/</link>
		<comments>http://fabiokung.com/2008/07/26/revising-my-opinion-about-spring-framework/#comments</comments>
		<pubDate>Sat, 26 Jul 2008 17:43:35 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[di]]></category>

		<category><![CDATA[ioc]]></category>

		<category><![CDATA[java]]></category>

		<category><![CDATA[spring]]></category>

		<category><![CDATA[spring ioc di framework opinion java]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=37</guid>
		<description><![CDATA[In past, at comm.world (Germany), I worked with projects based on Spring. At that time, I built my opinion about the framework: useless. It had nothing you couldn&#8217;t do without it. Everything that came with Spring could be done in simpler ways: PicoContainer or plain constructor injection for IoC/DI, plain decorators, dynamic proxies or Servlet [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>In past, at <a href="http://www.commworld.de/">comm.world</a> (Germany), I worked with projects based on Spring. At that time, I built my opinion about the framework: <strong>useless</strong>. It had nothing you couldn&#8217;t do without it. Everything that came with Spring could be done in simpler ways: <a href="http://www.picocontainer.org">PicoContainer</a> or plain constructor injection for IoC/DI, plain decorators, dynamic proxies or Servlet Filters instead of AOP for the same results, WebWork simpler than Spring MVC, &#8230;</p>
<p>Some time has passed and, influenced by some friends in our endless discussions about Spring, I&#8217;ve decided to give it another try and I&#8217;ve started to refactor the <a href="http://www.vraptor.org">VRaptor Web Framework</a>, changing it to be fully Spring-based.</p>
<p>After this experience, I must admit: I was <del datetime="00">a bit</del> wrong. I am going to explain it better, but I think the best part of Spring is that it already comes with many things done, ready to be used; out of the box. Furthermore, <a href="http://www.infoq.com/articles/spring-2.5-part-1">Spring 2.5 is much, much better</a>.</p>
<p>Now, I have the sense that Spring brings some complexity, compared to lightweight alternatives; but not that much. This is the cost for the benefits the framework introduces. It is extremely flexible, supporting many different programming styles and idioms. I would be able to completely rewrite VRaptor to use Spring building blocks. Most of the current frameworks could be changed to be Spring-based, with little influence in their current APIs and programming styles!</p>
<p>People has already <a href="http://www.jroller.com/Solomon/entry/guice_and_spring_2_51">(re)implemented Google Guice on top of Spring</a>. The EJB3 programming model (<code>@EJB</code>, <code>@PersistenceContext</code>, <code>@Stateless</code>, <code>@Stateful</code>, <code>@Resource</code>, &#8230;) can be easily replicated on Spring applications (<a href="http://www.onjava.com/pub/a/onjava/2005/06/29/spring-ejb3.html?page=2">old - 2005 - article that may be done better nowadays</a>). One could even provide an EJB3 implementation on top of Spring, JBoss Seam could be rewritten on top of Spring and even PicoContainer could be Spring-based.</p>
<p>My current opinion is that Spring is a truly <em>framework</em>, in its <a href="http://en.wikipedia.org/wiki/Software_framework">original sense</a>, because it acts as a solid base for applications to be built on top of it, <strong>without imposing</strong> any programming model, style or idiom. You aren&#8217;t required to use XML, Spring classes and even Spring annotations. The little bureaucracy comes with a bunch of ready functionality to be used, and with the great flexibility the framework has to be extended.</p>
<p>Today I can say I would consider using Spring Framework for new projects. I even consider it to be a good candidate to become <a href="http://www.infoq.com/news/2008/04/springsource-app-platform">one or more JSRs</a>. It is a great base for applications and other frameworks to be built on top of it. <a href="http://blog.springsource.com/main/2007/07/03/java-ee-6-gets-it-right">Rod Johnson is a member of Java EE 6 Expert Group</a>, which could point things to something in this direction.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/37/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/37/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/37/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=37&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/07/26/revising-my-opinion-about-spring-framework/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>
	</item>
		<item>
		<title>jetty_rails at RailsConf 2008</title>
		<link>http://fabiokung.com/2008/05/31/jetty_rails-at-railsconf-2008/</link>
		<comments>http://fabiokung.com/2008/05/31/jetty_rails-at-railsconf-2008/#comments</comments>
		<pubDate>Sat, 31 May 2008 18:26:42 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[conference]]></category>

		<category><![CDATA[jetty]]></category>

		<category><![CDATA[jruby]]></category>

		<category><![CDATA[rails]]></category>

		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=34</guid>
		<description><![CDATA[Jeremy Kemper talked about jetty_rails in his keynote at RailsConf 2008. Wow!

In the same keynote, Jeremy also made the official release of Rails 2.1. Unfortunately, I couldn&#8217;t go to RailsConf this year, but I hope to be in the next!
I&#8217;m extremely excited about this. Thanks to Nick Sieger (who talked to Jeremy about jetty_rails) and [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p><a href="http://en.oreilly.com/rails2008/public/schedule/speaker/21443">Jeremy Kemper</a> talked about <strong><a href="http://jetty-rails.rubyforge.org/">jetty_rails</a></strong> in his <a href="http://en.oreilly.com/rails2008/public/schedule/detail/4337">keynote at RailsConf 2008</a>. Wow!</p>
<p><a href="http://fabiokung.files.wordpress.com/2008/05/jetty_railsconf.jpg"><img src="http://fabiokung.files.wordpress.com/2008/05/jetty_railsconf.jpg?w=300&#038;h=225" alt="jetty_rails at Jeremy\&#39;s keynote" width="300" height="225" class="aligncenter size-medium wp-image-36" /></a></p>
<p>In the same keynote, Jeremy also made the <strong>official release of Rails 2.1</strong>. Unfortunately, I couldn&#8217;t go to RailsConf this year, but I hope to be in the next!</p>
<p>I&#8217;m extremely excited about this. Thanks to <a href="http://blog.nicksieger.com/">Nick Sieger</a> (who talked to Jeremy about jetty_rails) and <a href="http://akitaonrails.com">Fabio Akita</a> for the photo and great news.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/34/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/34/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/34/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/34/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/34/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=34&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/05/31/jetty_rails-at-railsconf-2008/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>

		<media:content url="http://fabiokung.files.wordpress.com/2008/05/jetty_railsconf.jpg?w=300" medium="image">
			<media:title type="html">jetty_rails at Jeremy\&#39;s keynote</media:title>
		</media:content>
	</item>
		<item>
		<title>JRuby and autotest (ZenTest)</title>
		<link>http://fabiokung.com/2008/05/27/jruby-and-autotest-zentest/</link>
		<comments>http://fabiokung.com/2008/05/27/jruby-and-autotest-zentest/#comments</comments>
		<pubDate>Tue, 27 May 2008 04:00:03 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[autotest]]></category>

		<category><![CDATA[jruby]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[tdd]]></category>

		<category><![CDATA[test]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=33</guid>
		<description><![CDATA[JRuby 1.1.2 is going to be released (probably) today and it fixes a bug with $~ constants (Regexp.last_match), which made autotest finally work!


jruby -S gem install ZenTest
cd myproject
jruby -S autotest


I&#8217;ve previously submitted a patch to ZenTest guys. It makes the use of autotest possible with any JRuby 1.x, but now, with JRuby 1.1.2, autotest should [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>JRuby 1.1.2 is going to be released (probably) today and it fixes a <a href="http://jira.codehaus.org/browse/JRUBY-2318">bug</a> with <code>$~</code> constants (<code>Regexp.last_match</code>), <strong>which made autotest finally work</strong>!</p>
<p><code>
<pre>
jruby -S gem install ZenTest
cd myproject
jruby -S autotest
</pre>
<p></code></p>
<p>I&#8217;ve previously <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=19773&amp;group_id=419&amp;atid=1680">submitted a patch</a> to ZenTest guys. It makes the use of autotest possible with any JRuby 1.x, but now, with JRuby 1.1.2, autotest should just work out of the box!</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/33/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/33/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/33/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/33/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/33/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=33&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/05/27/jruby-and-autotest-zentest/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>
	</item>
		<item>
		<title>jetty-rails 0.4 is also jetty-merb</title>
		<link>http://fabiokung.com/2008/05/22/jetty-rails-04-is-also-jetty-merb/</link>
		<comments>http://fabiokung.com/2008/05/22/jetty-rails-04-is-also-jetty-merb/#comments</comments>
		<pubDate>Thu, 22 May 2008 05:46:16 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[java]]></category>

		<category><![CDATA[jetty]]></category>

		<category><![CDATA[jruby]]></category>

		<category><![CDATA[merb]]></category>

		<category><![CDATA[rails]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=32</guid>
		<description><![CDATA[I&#8217;ve just released a new version of the jetty-rails gem. Now, you can also run Merb applications inside JRuby and Jetty!


jruby -S gem install jetty-rails
cd mymerbapp
jruby -S jetty_merb


Unfortunately, it&#8217;s blocking my console (ctrl + c doesn&#8217;t terminate it). Has anyone suggestions on this?
I&#8217;ve also updated the basic documentation, as you can see here.
The Merb support [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>I&#8217;ve just released a new version of the jetty-rails gem. Now, <strong>you can also run <a href="http://merbivore.com/">Merb</a> applications</strong> inside JRuby and Jetty!</p>
<p><code>
<pre>
jruby -S gem install jetty-rails
cd mymerbapp
jruby -S jetty_merb
</pre>
<p></code></p>
<p>Unfortunately, it&#8217;s blocking my console (ctrl + c doesn&#8217;t terminate it). Has anyone suggestions on this?</p>
<p>I&#8217;ve also updated the basic documentation, as you can see <a href="http://jetty-rails.rubyforge.org">here</a>.</p>
<p>The Merb support was actually done in <a href="http://wiki.jruby.org/wiki/JRuby_Rack">JRuby Rack</a>. It was quite simple to support it. Many thanks to Nick Sieger, Dudley Flanders e cia!</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/32/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/32/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/32/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=32&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/05/22/jetty-rails-04-is-also-jetty-merb/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>
	</item>
		<item>
		<title>jetty-rails gem - Simple JRuby On Rails Development with Servlet Containers</title>
		<link>http://fabiokung.com/2008/05/14/jetty-rails-gem-simple-jruby-on-rails-development-with-servlet-containers/</link>
		<comments>http://fabiokung.com/2008/05/14/jetty-rails-gem-simple-jruby-on-rails-development-with-servlet-containers/#comments</comments>
		<pubDate>Wed, 14 May 2008 05:47:51 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[java]]></category>

		<category><![CDATA[jetty]]></category>

		<category><![CDATA[jruby]]></category>

		<category><![CDATA[rails]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[servlet]]></category>

		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=30</guid>
		<description><![CDATA[This is the first time I&#8217;m writing about it, but jetty-rails is already 0.3!
Most people doing JRuby on Rails development are using JMongrels1 for development and some real Java Application Server in production.
The common flow is:


$ jruby script/server
=&#62; Booting Mongrel (use 'script/server webrick' to force WEBrick)
=&#62; Rails application starting on http://0.0.0.0:3000
=&#62; Call with -d to [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>This is the first time I&#8217;m writing about it, but <a href="http://jetty-rails.rubyforge.org/">jetty-rails</a> is already <strong>0.3</strong>!</p>
<p>Most people doing JRuby on Rails development are using JMongrels<a href="#jlet"><sup>1</sup></a> for development and some real Java Application Server in production.</p>
<p>The common flow is:</p>
<p><code>
<pre>
$ jruby script/server
=&gt; Booting Mongrel (use 'script/server webrick' to force WEBrick)
=&gt; Rails application starting on http://0.0.0.0:3000
=&gt; Call with -d to detach
=&gt; Ctrl-C to shutdown server
** Starting Mongrel listening at 0.0.0.0:3000
** Starting Rails with development environment...
</pre>
<p></code></p>
<p>code, code, test, code, code, test, &#8230; (shouldn&#8217;t it be red-green-refactor?) </p>
<p><code>
<pre>
$ jruby -S warble
$ cp myapp.war $TOMCAT_HOME/webapps
$ $TOMCAT_HOME/bin/startup.sh
</pre>
<p></code></p>
<p>Sure you can automate those things with ant, rake, sake or anything else. Some people are still using the goldspike-plugin, but be warned: I suspect it won&#8217;t get much more attention.</p>
<p>The great <a href="http://wiki.jruby.org/wiki/Warbler">Warbler</a> from <a href="http://blog.nicksieger.com/">Nick Sieger</a> is becoming the <em>de facto</em> standard for JRuby on Rails packaging. The <a href="http://blog.nicksieger.com/articles/2008/05/08/introducing-jruby-rack">Warbler&#8217;s recent move from goldspike to JRuby-Rack adapter</a> reveals two interesting points:</p>
<ol>
<li>Goldspike is likely going to be deprecated (or merged with jruby-rack adapter?).</li>
<li>Warbler will soon package any rack compatible application to be runned inside Java Containers. Such applications include Merb, Sinatra, Vintage, Camping ones, <a href="http://rack.rubyforge.org/">and growing</a>&#8230;</li>
</ol>
<p>Although Warbler works really well, it introduces complexity in the development cycle. You can no more save code and immediately test it in your browser:</p>
<ol>
<li>change code;</li>
<li>warble it;</li>
<li>deploy war file;</li>
<li><strong>restart server;</strong> (takes long time)</li>
<li>open browser;</li>
<li>change code;</li>
<li>&#8230;</li>
</ol>
<p>It breaks one of the most important rails development characteristics: <strong>instant feedback</strong>. During development, it&#8217;s very important to see changes without have to wait for server/context restarting.</p>
<p>JMongrel and <a href="http://wiki.glassfish.java.net/Wiki.jsp?page=JRuby">Glassfish Gem</a> are good candidates for JRuby on Rails development with instant feedback, but you can&#8217;t use Java (Servlet specification) specific features, such as <em>web.xml</em>; they aren&#8217;t complete Servlet Containers. Some things have an alternative in pure-rails as Servlet Filters and Servlet Listeners, but many haven&#8217;t. Servlet Context might be a good way to share things between rails runtimes. I know railers should <em>&#8220;share nothing&#8221;</em>, but -hey- sometimes it&#8217;s <strong>so good</strong> to share!</p>
<p>You can take the Servlet Application Context as your <strong>in-memory cache store</strong> (fragment and page caching), eliminating the need for filesystem or database overhead and even memcached, in many cases.</p>
<p>I had also a specific reason to share the same HttpSession between Rails and &#8220;pure Java&#8221; applications. Single sign-on wasn&#8217;t an option, so I needed to run both applications in the same context. I&#8217;m going to tell more about it soon.</p>
<p>Anyone can fall in cases, like mine, when you just can&#8217;t use jmongrel or glassfish_rails. Now, we fortunately have <a href="http://jetty-rails.rubyforge.org">jetty-rails</a> to rescue!</p>
<p>It&#8217;s a (<del datetime="00">one more</del>) gem to run rails applications, based on the nice <a href="http://wiki.jruby.org/wiki/JRuby_Rack">JRuby-Rack adapter</a>, which I recommend you to take a look. Jetty is a very powerful Servlet Container, known for being pioneer at being embedded and at using NIO Connectors.</p>
<p>The gem creates a Jetty Server with two Handlers. The first is for static content and the last to serve dynamic requests using JRuby-Rack. These handlers are applied in order and request processing stops when one responds. That way, no rails code is runned to serve static content, improving response times. Take a look at the <a href="http://jetty-rails.rubyforge.org/rdoc/">rdocs</a> for more details.</p>
<p>Jetty is also very quick to start. I&#8217;ve measured (in a complete inaccurate way) some start times just for <del datetime="00">ugly</del><a href="#ugly-method"><sup>2</sup></a> comparison:</p>
<p><code>
<pre>$ jruby -v
<strong>ruby 1.8.6 (2008-03-28 rev 6360) [i386-jruby1.1]</strong>
$ time <strong>jruby script/server</strong>
=&gt; Booting Mongrel (use 'script/server webrick' to force WEBrick)
=&gt; Rails application starting on http://0.0.0.0:3000
...
** INT signal received.
Exiting

<strong>real	0m13.947s</strong>
user	0m11.327s
sys	0m0.892s
</pre>
<p></code></p>
<p><code>
<pre>$ ruby -v
<strong>ruby 1.8.6 (2007-09-24 patchlevel 111) [universal-darwin9.0]</strong>
$ time <strong>./script/server </strong>
=&gt; Booting Mongrel (use 'script/server webrick' to force WEBrick)
=&gt; Rails application starting on http://0.0.0.0:3000
...
** INT signal received.
Exiting

<strong>real	0m6.273s</strong>
user	0m1.893s
sys	0m0.611s
</pre>
<p></code></p>
<p>With the same JRuby 1.1 (and without Charles recent speedup patch for jruby startup):</p>
<p><code>
<pre>$ time <strong>jruby -S jetty_rails</strong>
2008-05-04 10:50:00.846::INFO:  Logging to STDERR via org.mortbay.log.StdErrLog
2008-05-04 10:50:01.013::INFO:  jetty-6.1.9
...
2008-05-04 10:50:02.987::INFO:  Started SelectChannelConnector@0.0.0.0:8080

<strong>real	0m7.035s</strong>
user	0m4.387s
sys	0m0.296s
</pre>
<p></code></p>
<p>As you can see, jetty_rails is very close to mongrel running in MRI, but please, don&#8217;t take those numbers so seriously.</p>
<p>Jetty Rails should be ready to run any rails application (tell me otherwise!) with no dependencies on extra jars. All gems used by the application must be installed in your JRuby. I&#8217;ve made some simple benchmarks with <a href="http://jakarta.apache.org/jmeter/">JMeter</a> and only one thread, firing 500 consecutive requests to a simple rails blog application. All requests pointed to &#8216;/posts&#8217; controller, and there was only one Post is the MySQL database.</p>
<p>The machine used to run all tests is a Intel Core2 Duo E4500 @ 2.20GHz, 2.0GB RAM, running Ubuntu 7.10, Ruby (MRI) 1.8.6 and JRuby 1.1.1. MRI tests were done using plain ruby activerecord-mysql-adapter and JRuby tests were done using activerecord-jdbcmysql-adapter.</p>
<p>Mongrel: 30.7 req/s<br />
JMongrel: 19.1 req/s</p>
<p>Glassfish Gem: 17.5 req/s<br />
dropping JVM warm time: 23.8 req/s</p>
<p><strong>Jetty Rails</strong>: 18.2 req/s<br />
dropping JVM warm time: <strong>26.6 req/s</strong></p>
<p>This is obviously a simple measure, just to feel how jetty-rails is going. But I&#8217;m very happy with the results. If we ignore the time that JVM takes to warm and JIT compile things, jetty-rails comes close to Mongrel! Impressive. I knew Jetty was always very fast, but I really didn&#8217;t expect those results.</p>
<p><a href="http://github.com/fabiokung/jetty-rails/tree/master/TODO.txt">There is much more to do</a>. Things from the <a href="http://github.com/fabiokung/jetty-rails/tree/master/TODO.txt">roadmap</a> I wanted to see working soon include:</p>
<ul>
<li>read warble.rb configuration files and register extra jars and public folders defined there;</li>
<li>use any custom web.xml defined in config/web.xml (or config/web.erb.xml), following Wabler conventions.</li>
<li>jetty_merb</li>
<li>jetty_camping</li>
<li>&#8230;</li>
</ul>
<p>The <a href="http://github.com/fabiokung/jetty-rails/tree/master">source code lives in GitHub</a>. Feel free to fork, contribute, send patches and suggestions!</p>
<p>
<hr />
<ol>
<li><a name="jlet">Can we stop calling everything that comes from Java with that <del datetime="00">damn</del> <strong>J</strong>-at-start or with -<strong>let</strong> termination? <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </a></li>
<li><a name="ugly-method">I&#8217;ve stopped the processes (ctrl+c) as soon as I saw they were ready to respond to requests.</a></li>
</ol>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/30/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/30/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/30/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/30/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/30/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=30&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/05/14/jetty-rails-gem-simple-jruby-on-rails-development-with-servlet-containers/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>
	</item>
		<item>
		<title>Word Movement in OS X Leopard Terminal.app</title>
		<link>http://fabiokung.com/2008/04/15/word-movement-in-os-x-leopard-terminalapp/</link>
		<comments>http://fabiokung.com/2008/04/15/word-movement-in-os-x-leopard-terminalapp/#comments</comments>
		<pubDate>Tue, 15 Apr 2008 16:06:25 +0000</pubDate>
		<dc:creator>Fabio Kung</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://fabiokung.wordpress.com/?p=24</guid>
		<description><![CDATA[Word movement in OS X Leopard Terminal.app is a pain! After long time searching, I must keep the solution documented here.
I&#8217;ve been searching for a long time, how to fix home/end keys and how to jump words. In every OS X application, cmd + arrows and option + arrows would do the trick, except Terminal.app. [...]]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Word movement in OS X Leopard Terminal.app is a pain! After long time searching, I must keep the solution documented here.</p>
<p>I&#8217;ve been searching for a long time, how to fix home/end keys and how to jump words. In every OS X application, <code>cmd + arrows</code> and <code>option + arrows</code> would do the trick, except Terminal.app. I had once fixed it for OS X Tiger, but I couldn&#8217;t remember how&#8230;</p>
<p>Finally, <a href="http://blog.macromates.com/2006/word-movement-in-terminal/">I&#8217;ve found it</a>. Thanks Textmate guys!</p>
<p>My choice is for <code>fn + arrows</code> (home/end) to begin/end of lines and <code>ctrl + arrows</code> to jump words. Fire your Terminal.app, hit <code>cmd + ,</code> (yes, period); the alternative is Terminal -&gt; Preferences. Go to <em>Settings</em> area, then <em>Keyboard</em> tab. Edit your combos as below:</p>
<p><a href="http://fabiokung.files.wordpress.com/2008/04/keyboard-settings.png"><img class="alignright size-full wp-image-25" src="http://fabiokung.files.wordpress.com/2008/04/keyboard-settings.png?w=374&#038;h=95" alt="Terminal.app keyboard settings" width="374" height="95" /></a></p>
<p>The trick is the code <code>&#92;033b</code>. It is produced through <strong><code>esc (&#92;033) + b</code></strong> and represents <em>&#8220;move one word backward&#8221;</em>. Forward movement is <strong><code>esc + f</code></strong>, <em>home</em> is <strong><code>ctrl + a (&#92;001)</code></strong> and <em>end</em> is <strong><code>ctrl + e (&#92;005)</code></strong>.</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/fabiokung.wordpress.com/24/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/fabiokung.wordpress.com/24/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/fabiokung.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/fabiokung.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/fabiokung.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/fabiokung.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/fabiokung.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/fabiokung.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/fabiokung.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/fabiokung.wordpress.com/24/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/fabiokung.wordpress.com/24/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/fabiokung.wordpress.com/24/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=fabiokung.com&blog=3424388&post=24&subd=fabiokung&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://fabiokung.com/2008/04/15/word-movement-in-os-x-leopard-terminalapp/feed/</wfw:commentRss>
	
		<media:content url="http://a.wordpress.com/avatar/fabiokung-128.jpg" medium="image">
			<media:title type="html">Fabio Kung</media:title>
		</media:content>

		<media:content url="http://fabiokung.files.wordpress.com/2008/04/keyboard-settings.png" medium="image">
			<media:title type="html">Terminal.app keyboard settings</media:title>
		</media:content>
	</item>
	</channel>
</rss>