<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns: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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>JPz'log</title>
	
	<link>http://jpz-log.info</link>
	<description>Coin Coin and Plop da Plop</description>
	<pubDate>Wed, 17 Jun 2009 08:58:32 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/JPzLog" type="application/rss+xml" /><feedburner:feedFlare href="http://add.my.yahoo.com/rss?url=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif">Subscribe with My Yahoo!</feedburner:feedFlare><feedburner:feedFlare href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://www.newsgator.com/images/ngsub1.gif">Subscribe with NewsGator</feedburner:feedFlare><feedburner:feedFlare href="http://feeds.my.aol.com/add.jsp?url=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://o.aolcdn.com/favorites.my.aol.com/webmaster/ffclient/webroot/locale/en-US/images/myAOLButtonSmall.gif">Subscribe with My AOL</feedburner:feedFlare><feedburner:feedFlare href="http://www.bloglines.com/sub/http://feeds.feedburner.com/JPzLog" src="http://www.bloglines.com/images/sub_modern11.gif">Subscribe with Bloglines</feedburner:feedFlare><feedburner:feedFlare href="http://www.netvibes.com/subscribe.php?url=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://www.netvibes.com/img/add2netvibes.gif">Subscribe with Netvibes</feedburner:feedFlare><feedburner:feedFlare href="http://fusion.google.com/add?feedurl=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://buttons.googlesyndication.com/fusion/add.gif">Subscribe with Google</feedburner:feedFlare><feedburner:feedFlare href="http://www.pageflakes.com/subscribe.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://www.pageflakes.com/ImageFile.ashx?instanceId=Static_4&amp;fileName=ATP_blu_91x17.gif">Subscribe with Pageflakes</feedburner:feedFlare><feedburner:feedFlare href="http://my.feedlounge.com/external/subscribe?url=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://static.feedlounge.com/buttons/subscribe_0.gif">Subscribe with FeedLounge</feedburner:feedFlare><feedburner:feedFlare href="http://www.live.com/?add=http%3A%2F%2Ffeeds.feedburner.com%2FJPzLog" src="http://tkfiles.storage.msn.com/x1piYkpqHC_35nIp1gLE68-wvzLZO8iXl_JMledmJQXP-XTBOLfmQv4zhj4MhcWEJh_GtoBIiAl1Mjh-ndp9k47If7hTaFno0mxW9_i3p_5qQw">Subscribe with Live.com</feedburner:feedFlare><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com" /><item>
		<title>IzPack 4.3.1 is available</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/AV0Pm8yxmtw/</link>
		<comments>http://jpz-log.info/archives/2009/06/17/izpack-431-is-available/#comments</comments>
		<pubDate>Wed, 17 Jun 2009 08:58:32 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[IzPack]]></category>

		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=630</guid>
		<description><![CDATA[I&#8217;m pleased to let the world know of the availability of IzPack 4.3.1  
This is a maintenance release. While it is not very spectacular by itself, upgrading is still a very good idea as you will grab a few fixes there and there.
Many thanks to our community (developers, contributors, issue reporters and users) for [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m pleased to let the world know of the availability of <a href="http://izpack.org/">IzPack 4.3.1</a> <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>This is a maintenance release. While it is not very spectacular by itself, upgrading is still a very good idea as you will grab a few fixes there and there.</p>
<p>Many thanks to our community (developers, contributors, issue reporters and users) for making this release possible, and go to <a href="http://izpack.org/">http://izpack.org</a> to get your copy today!</p>

<p><a href="http://feedads.g.doubleclick.net/~a/XPAj1PZGsGk8XQnQLjSfe_oVbGw/0/da"><img src="http://feedads.g.doubleclick.net/~a/XPAj1PZGsGk8XQnQLjSfe_oVbGw/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/XPAj1PZGsGk8XQnQLjSfe_oVbGw/1/da"><img src="http://feedads.g.doubleclick.net/~a/XPAj1PZGsGk8XQnQLjSfe_oVbGw/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=AV0Pm8yxmtw:-l9AD3tR7bc:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=AV0Pm8yxmtw:-l9AD3tR7bc:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/AV0Pm8yxmtw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/06/17/izpack-431-is-available/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/06/17/izpack-431-is-available/</feedburner:origLink></item>
		<item>
		<title>Support the IzPack development by making a donation!</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/SvFesphuJbw/</link>
		<comments>http://jpz-log.info/archives/2009/06/11/support-the-izpack-development-by-making-a-donation/#comments</comments>
		<pubDate>Thu, 11 Jun 2009 10:09:56 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[IzPack]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=623</guid>
		<description><![CDATA[Hi everyone,
As you can easily guess, maintaining and developing IzPack since 2001 has been a lot of fun&#8230; and also a significant time investment  
I am already offering professional services for those who would need support, consulting and custom developments (see http://izpack.proservices.ponge.info/). A few companies also give back to the project in the form [...]]]></description>
			<content:encoded><![CDATA[<p>Hi everyone,</p>
<p>As you can easily guess, maintaining and developing IzPack since 2001 has been a lot of fun&#8230; and also a significant time investment <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>I am already offering professional services for those who would need support, consulting and custom developments (see <a href="http://izpack.proservices.ponge.info/">http://izpack.proservices.ponge.info/</a>). A few companies also give back to the project in the form of patches and contributors / developers: thanks to you all!</p>
<p>However, the large majority of IzPack users simply download it and never give back anything. This is perfectly fine of course, but <strong>I would like to let you know that you can support my very own work on this project by making a donation <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </strong></p>
<p>To do that, you can use the following link <em>(note that you will receive both my gratitude AND a true invoice)</em>.</p>
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="6069711">
<input type="image" src="https://www.paypal.com/en_US/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.paypal.com/fr_FR/i/scr/pixel.gif" width="1" height="1"><br />
</form>
<p>Thanks for your support!</p>
<p><em>(ps: for those who may ask, the adsense units on the website mainly cover the domain name and web hosting)</em></p>

<p><a href="http://feedads.g.doubleclick.net/~a/eXzNKw4PptFxEwmfYUkA4GO3ju0/0/da"><img src="http://feedads.g.doubleclick.net/~a/eXzNKw4PptFxEwmfYUkA4GO3ju0/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/eXzNKw4PptFxEwmfYUkA4GO3ju0/1/da"><img src="http://feedads.g.doubleclick.net/~a/eXzNKw4PptFxEwmfYUkA4GO3ju0/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=SvFesphuJbw:m043AWGtpMo:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=SvFesphuJbw:m043AWGtpMo:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/SvFesphuJbw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/06/11/support-the-izpack-development-by-making-a-donation/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/06/11/support-the-izpack-development-by-making-a-donation/</feedburner:origLink></item>
		<item>
		<title>Discovering Grails Web Flows</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/QWOomLjBtnY/</link>
		<comments>http://jpz-log.info/archives/2009/06/01/discovering-grails-web-flows/#comments</comments>
		<pubDate>Mon, 01 Jun 2009 14:42:33 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[Geeking]]></category>

		<category><![CDATA[Groovy]]></category>

		<category><![CDATA[Java]]></category>

		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=613</guid>
		<description><![CDATA[I recently discovered Grails Web Flows. This is basically a Groovy DSL on top of Spring Web Flows.
I did a quick dirty and imperfect example which is a number guessing game. I took inspiration from another Grails Web Flows tutorial.
In this post, I will limit myself to some very quick description of web flows, and [...]]]></description>
			<content:encoded><![CDATA[<p>I recently discovered <a href="http://www.grails.org/WebFlow">Grails Web Flows</a>. This is basically a Groovy DSL on top of <a href="http://www.springframework.org/webflow">Spring Web Flows</a>.</p>
<p>I did a <em>quick dirty and imperfect</em> example which is a number guessing game. I took inspiration from another <a href="http://wijlens.com/index.php?option=com_content&amp;task=view&amp;id=22&amp;Itemid=31">Grails Web Flows tutorial</a>.</p>
<p>In this post, I will limit myself to some very quick description of web flows, and I urge you to read the documentations (from Grails and Spring). The idea behind web flows is to provide a framework for web conversations that span multiple HTTP requests, such as wizards, payment processes and such. A &#8220;web flow&#8221; is modeled as a state machine, where:</p>
<ul>
<li>states represent either an <strong>action</strong> (i.e., some code) or a <strong>view</strong>, and</li>
<li>transitions are triggered based on the outcome from the state, which is a simple string.</li>
</ul>
<p>As such, web flows free the developer from much repetitive logic when you need to control states of a web conversation.</p>
<p>In this example, the number to guess is 25 (we could have made it non-static, but who cares?). The user has 5 attempts. The corresponding flow is:</p>
<p><img class="aligncenter size-full wp-image-614" title="flow" src="http://jpz-log.info/wp-content/uploads/2009/06/flow.png" alt="flow" width="254" height="537" /></p>
<p>Grails provides web flows out of the box. All you have to do is to create a special controller closure property which ends by &#8220;<code>Flow</code>&#8220;:</p>

<div class="wp_syntax"><div class="code"><pre class="groovy" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">class</span> GuessController
<span style="color: #66cc66;">&#123;</span>
&nbsp;
  <span style="color: #000000; font-weight: bold;">def</span> toGuess <span style="color: #66cc66;">=</span> <span style="color: #ff0000;">&quot;25&quot;</span>
&nbsp;
  <span style="color: #000000; font-weight: bold;">def</span> index <span style="color: #66cc66;">=</span> <span style="color: #66cc66;">&#123;</span>
    redirect<span style="color: #66cc66;">&#40;</span>action: <span style="color: #ff0000;">&quot;guess&quot;</span><span style="color: #66cc66;">&#41;</span>
  <span style="color: #66cc66;">&#125;</span>
&nbsp;
  <span style="color: #000000; font-weight: bold;">def</span> guessFlow <span style="color: #66cc66;">=</span> <span style="color: #66cc66;">&#123;</span> ... <span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #66cc66;">&#125;</span></pre></div></div>

<p>We now have to define the &#8220;<code>guess</code>&#8221; flow. As often in Groovy and Grails, it boils down to some intuitive builder structure:</p>

<div class="wp_syntax"><div class="code"><pre class="groovy" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">class</span> GuessController
<span style="color: #66cc66;">&#123;</span>
&nbsp;
  <span style="color: #000000; font-weight: bold;">def</span> toGuess <span style="color: #66cc66;">=</span> <span style="color: #ff0000;">&quot;25&quot;</span>
&nbsp;
  <span style="color: #000000; font-weight: bold;">def</span> index <span style="color: #66cc66;">=</span> <span style="color: #66cc66;">&#123;</span>
    redirect<span style="color: #66cc66;">&#40;</span>action: <span style="color: #ff0000;">&quot;guess&quot;</span><span style="color: #66cc66;">&#41;</span>
  <span style="color: #66cc66;">&#125;</span>
&nbsp;
  <span style="color: #000000; font-weight: bold;">def</span> guessFlow <span style="color: #66cc66;">=</span> <span style="color: #66cc66;">&#123;</span>
&nbsp;
    <span style="color: #993399;">start</span> <span style="color: #66cc66;">&#123;</span>
      action <span style="color: #66cc66;">&#123;</span>
        <span style="color: #66cc66;">&#91;</span>guessLeft: <span style="color: #cc66cc;">5</span><span style="color: #66cc66;">&#93;</span>
      <span style="color: #66cc66;">&#125;</span>
      on<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;success&quot;</span><span style="color: #66cc66;">&#41;</span>.<span style="color: #006600;">to</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;ask&quot;</span><span style="color: #66cc66;">&#41;</span>
    <span style="color: #66cc66;">&#125;</span>
&nbsp;
    ask <span style="color: #66cc66;">&#123;</span>
      on<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;evaluate&quot;</span><span style="color: #66cc66;">&#41;</span>.<span style="color: #006600;">to</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;evaluate&quot;</span><span style="color: #66cc66;">&#41;</span>
    <span style="color: #66cc66;">&#125;</span>
&nbsp;
    done<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>
&nbsp;
    fail<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>
&nbsp;
    evaluate <span style="color: #66cc66;">&#123;</span>
      action <span style="color: #66cc66;">&#123;</span>
        <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>params.<span style="color: #006600;">number</span> <span style="color: #66cc66;">==</span> toGuess<span style="color: #66cc66;">&#41;</span>
        <span style="color: #66cc66;">&#123;</span>
          <span style="color: #000000; font-weight: bold;">return</span> yes<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>
        <span style="color: #66cc66;">&#125;</span>
        flow.<span style="color: #006600;">guessLeft</span> <span style="color: #66cc66;">=</span> flow.<span style="color: #006600;">guessLeft</span> <span style="color: #66cc66;">-</span> <span style="color: #cc66cc;">1</span>
        <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>flow.<span style="color: #006600;">guessLeft</span> <span style="color: #66cc66;">==</span> <span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#41;</span>
        <span style="color: #66cc66;">&#123;</span>
          <span style="color: #000000; font-weight: bold;">return</span> loose<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>
        <span style="color: #66cc66;">&#125;</span>
        <span style="color: #b1b100;">else</span>
        <span style="color: #66cc66;">&#123;</span>
          <span style="color: #000000; font-weight: bold;">return</span> no<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>
        <span style="color: #66cc66;">&#125;</span>
      <span style="color: #66cc66;">&#125;</span>
      on<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;yes&quot;</span><span style="color: #66cc66;">&#41;</span>.<span style="color: #006600;">to</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;done&quot;</span><span style="color: #66cc66;">&#41;</span>
      on<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;no&quot;</span><span style="color: #66cc66;">&#41;</span>.<span style="color: #006600;">to</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;ask&quot;</span><span style="color: #66cc66;">&#41;</span>
      on<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;loose&quot;</span><span style="color: #66cc66;">&#41;</span>.<span style="color: #006600;">to</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;fail&quot;</span><span style="color: #66cc66;">&#41;</span>
    <span style="color: #66cc66;">&#125;</span>
  <span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span></pre></div></div>

<ol>
<li><code>start</code> is an <strong>action state</strong>, which is called first, and that puts a <code>guessLeft</code> variable in the flow context.</li>
<li>The <code>ask</code> state displays a web page, then delegates the logic to the <code>evaluate</code> action state.</li>
<li>The <code>evaluate</code> action state either pushes the flow to the final states, or loops back to the <code>ask</code> state if there are guesses left.</li>
<li><code>done</code> and <code>fail</code> are final states that just show some web pages.</li>
</ol>
<p>Finally there are 3 views that you need to create. Since the web flow is named &#8220;guess&#8221;, they must be in a special &#8220;<code>guess</code>&#8221; subfolder of the matching controller views. Also, they must be named by the state names.</p>
<p><strong>ask.gsp</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;%@ page contentType=&quot;text/html;charset=UTF-8&quot; %&gt;
&lt;html&gt;
  &lt;head&gt;&lt;title&gt;Simple GSP page&lt;/title&gt;&lt;/head&gt;
  &lt;body&gt;
&nbsp;
  &lt;g:javascript library=&quot;prototype&quot;/&gt;
  &lt;g:javascript&gt;
    document.observe(&quot;dom:loaded&quot;, function() {
      $(&quot;field&quot;).focus();  
    });
  &lt;/g:javascript&gt;
&nbsp;
  &lt;h1&gt;Guess&lt;/h1&gt;
  &lt;p&gt;Guesses left: &lt;strong&gt;${guessLeft}&lt;/strong&gt;.&lt;/p&gt;
&nbsp;
  &lt;p&gt;
    &lt;g:form action=&quot;guess&quot;&gt;
      &lt;g:textField id=&quot;field&quot; name=&quot;number&quot; value=&quot;0&quot; /&gt;
      &lt;g:submitButton name=&quot;evaluate&quot; value=&quot;Try this number!&quot; /&gt;
    &lt;/g:form&gt;
  &lt;/p&gt;
&nbsp;
  &lt;/body&gt;
&lt;/html&gt;</pre></div></div>

<p>Note that the <code>guessLeft</code> flow context variable is available directly in the GSP. Also, note that the form action must match the web flow name and that the submit button name is the outcome of the view state.</p>
<p><strong>done.gsp</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;%@ page contentType=&quot;text/html;charset=UTF-8&quot; %&gt;
&lt;html&gt;
  &lt;head&gt;&lt;title&gt;Simple GSP page&lt;/title&gt;&lt;/head&gt;
  &lt;body&gt;You won!&lt;/body&gt;
&lt;/html&gt;</pre></div></div>

<p><strong>fail.gsp</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">&lt;%@ page contentType=&quot;text/html;charset=UTF-8&quot; %&gt;
&lt;html&gt;
  &lt;head&gt;&lt;title&gt;Simple GSP page&lt;/title&gt;&lt;/head&gt;
  &lt;body&gt;You failed...&lt;/body&gt;
&lt;/html&gt;</pre></div></div>


<p><a href="http://feedads.g.doubleclick.net/~a/othh8EqFJL37NIdqKA9YZ4214i4/0/da"><img src="http://feedads.g.doubleclick.net/~a/othh8EqFJL37NIdqKA9YZ4214i4/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/othh8EqFJL37NIdqKA9YZ4214i4/1/da"><img src="http://feedads.g.doubleclick.net/~a/othh8EqFJL37NIdqKA9YZ4214i4/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=QWOomLjBtnY:iz18NcYnHI4:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=QWOomLjBtnY:iz18NcYnHI4:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/QWOomLjBtnY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/06/01/discovering-grails-web-flows/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/06/01/discovering-grails-web-flows/</feedburner:origLink></item>
		<item>
		<title>Taking SWT/Cocoa and MigLayout for a spin</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/qDQCTb_mFN8/</link>
		<comments>http://jpz-log.info/archives/2009/05/23/taking-swtcocoa-and-miglayout-for-a-spin/#comments</comments>
		<pubDate>Sat, 23 May 2009 20:15:53 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[Geeking]]></category>

		<category><![CDATA[IzPack]]></category>

		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=602</guid>
		<description><![CDATA[It&#8217;s been a while since I last had a look at SWT (the so-called &#8220;standard widget tookit&#8221;). One very good reason is probably the fact that I have switched to Mac OS X, and the Mac SWT port used to suck badly. To convince yourself, download Eclipse and play with it. I&#8217;m sure you&#8217;ll feel [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a while since I last had a look at <a href="http://www.eclipse.org/swt/">SWT</a> (the so-called<em> &#8220;standard widget tookit&#8221;</em>). One very good reason is probably the fact that I have switched to Mac OS X, and the Mac SWT port used to suck badly. To convince yourself, download <a href="http://www.eclipse.org/">Eclipse</a> and play with it. I&#8217;m sure you&#8217;ll feel that it does not really look like a true Mac OS X application, and you will easily spot UI glitches there and there (tip: edit a field in a table, just for fun). This is even more critical when Swing applications like IntelliJ IDEA or Netbeans look so great while relying on a non-native toolkit&#8230;</p>
<p> SWT is still a very capable GUI toolkit. Although the API feels a lot more low-level than Swing, you can get some satisfying rsults by using it. It is not a <a href="http://filthyrichclients.org/">Filthy Rich Clients</a> compatible toolkit (forget the slick interfaces that you can make on top of Swing), but some stuff can become way easier in the world of SWT than in the world of Swing (e.g., embedding a web browser or getting a truly native file dialog). Another good reason for keeping SWT under the radar is that it is actively developed while one can reasonably fear that Swing is&#8230; more in a kind of maintenance mode to say the least.</p>
<p>The SWT team recently took the Mac OS X matters seriously and decided to port it over Cocoa, the framework upon which true Mac OS X applications should be built. Indeed, the existing port used to be made over Carbon, the now deprecated Mac APIs that endanger the future of Eclipse on Mac OS X. Although this is still work in progress, SWT/Cocoa is just great (and Eclipse is probably going to look ok on a Mac, although I am not going to switch back to it any time soon).</p>
<p>I took it for a spin to build a very stupid application:</p>
<p><a href="http://jpz-log.info/wp-content/uploads/2009/05/swtapp.png"><img src="http://jpz-log.info/wp-content/uploads/2009/05/swtapp.png" alt="swtapp" title="swtapp" width="446" height="244" class="alignnone size-full wp-image-603" /></a></p>
<p>If you press the button, a message box shows up to repeat the informations. It also features a label with an hyperlink that pops up a web browser.</p>
<p>Good layouts are both critical (otherwise your application looks like a toy) and hard to realize. I used the fantastic <a href="http://miglayout.com/">MigLayout libary</a>. There is a version for both Swing and SWT. It is somehow reminiscent of the JGoodies layouts, and the extra bonus is that the library weights really nothing.</p>
<p>My main class is fairly standard for a SWT application:</p>

<div class="wp_syntax"><div class="code"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> Main
<span style="color: #009900;">&#123;</span>
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">void</span> main<span style="color: #009900;">&#40;</span><span style="color: #003399;">String</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> args<span style="color: #009900;">&#41;</span>
    <span style="color: #009900;">&#123;</span>
        Display display <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Display<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        Shell shell <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Shell<span style="color: #009900;">&#40;</span>display, SWT.<span style="color: #006633;">SHELL_TRIM</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        shell.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Swt/Cocoa&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">new</span> MyController<span style="color: #009900;">&#40;</span>shell<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        shell.<span style="color: #006633;">pack</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        shell.<span style="color: #006633;">open</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>shell.<span style="color: #006633;">isDisposed</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
        <span style="color: #009900;">&#123;</span>
            <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>display.<span style="color: #006633;">readAndDispatch</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
            <span style="color: #009900;">&#123;</span>
                display.<span style="color: #006633;">sleep</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span>
&nbsp;
        display.<span style="color: #006633;">dispose</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>My &#8220;controller&#8221; (which should have not be named like that since it is not a true controller&#8230;) is relatively simple too:</p>

<div class="wp_syntax"><div class="code"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> MyController
<span style="color: #009900;">&#123;</span>
    <span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">final</span> Shell shell<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">public</span> MyController<span style="color: #009900;">&#40;</span>Shell shell<span style="color: #009900;">&#41;</span>
    <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">shell</span> <span style="color: #339933;">=</span> shell<span style="color: #339933;">;</span>
        initialize<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
    <span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">void</span> initialize<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
    <span style="color: #009900;">&#123;</span>
        <span style="color: #000000; font-weight: bold;">final</span> MigLayout layout <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> MigLayout<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;fillx&quot;</span>, <span style="color: #0000ff;">&quot;[right] rel [grow, fill]&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        shell.<span style="color: #006633;">setLayout</span><span style="color: #009900;">&#40;</span>layout<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">final</span> <span style="color: #003399;">Label</span> nameLabel <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">Label</span><span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">NONE</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        nameLabel.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Name:&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">final</span> Text nameText <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Text<span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">SINGLE</span> <span style="color: #339933;">|</span> SWT.<span style="color: #006633;">BORDER</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        nameText.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Somebody&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        nameText.<span style="color: #006633;">setLayoutData</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;wrap, width 300px&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">final</span> <span style="color: #003399;">Label</span> emailLabel <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">Label</span><span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">NONE</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        emailLabel.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Email:&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">final</span> Text emailText <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Text<span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">SINGLE</span> <span style="color: #339933;">|</span> SWT.<span style="color: #006633;">BORDER</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        emailText.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;foo@bar.com&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        emailText.<span style="color: #006633;">setLayoutData</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;wrap&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">final</span> <span style="color: #003399;">Button</span> displayButton <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">Button</span><span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">PUSH</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        displayButton.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Display&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        displayButton.<span style="color: #006633;">setLayoutData</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;span 2, tag ok, gapy unrelated, wrap&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #000000; font-weight: bold;">final</span> Link urlLink <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Link<span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">NONE</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        urlLink.<span style="color: #006633;">setText</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&lt;a&gt;More informations...&lt;/a&gt;&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        urlLink.<span style="color: #006633;">addSelectionListener</span><span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">new</span> SelectionAdapter<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
        <span style="color: #009900;">&#123;</span>
            @Override
            <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> widgetSelected<span style="color: #009900;">&#40;</span>SelectionEvent selectionEvent<span style="color: #009900;">&#41;</span>
            <span style="color: #009900;">&#123;</span>
                Program.<span style="color: #006633;">launch</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;http://jpz-log.info/&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        urlLink.<span style="color: #006633;">setLayoutData</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;span 2, align left, gapy unrelated, wrap&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        shell.<span style="color: #006633;">setDefaultButton</span><span style="color: #009900;">&#40;</span>displayButton<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        displayButton.<span style="color: #006633;">addSelectionListener</span><span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">new</span> SelectionAdapter<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
        <span style="color: #009900;">&#123;</span>
            @Override
            <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> widgetSelected<span style="color: #009900;">&#40;</span>SelectionEvent selectionEvent<span style="color: #009900;">&#41;</span>
            <span style="color: #009900;">&#123;</span>
                <span style="color: #003399;">String</span> normalForm <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> StringBuilder<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #006633;">append</span><span style="color: #009900;">&#40;</span>nameText.<span style="color: #006633;">getText</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #006633;">append</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot; &lt;&quot;</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #006633;">append</span><span style="color: #009900;">&#40;</span>emailText.<span style="color: #006633;">getText</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #006633;">append</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&gt;&quot;</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #006633;">toString</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
                MessageBox box <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> MessageBox<span style="color: #009900;">&#40;</span>shell, SWT.<span style="color: #006633;">ICON_INFORMATION</span> <span style="color: #339933;">|</span> SWT.<span style="color: #006633;">OK</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                box.<span style="color: #006633;">setMessage</span><span style="color: #009900;">&#40;</span>normalForm<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                box.<span style="color: #006633;">open</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Simple isn&#8217;t it? <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Of course it could have been made even more compact by using Groovy, Scala or JRuby&#8230;</p>
<p>One last thing: SWT applications need a special <code>-XstartOnFirstThread</code> JVM flag on Mac OS X.</p>

<p><a href="http://feedads.g.doubleclick.net/~a/RLcthwbrGX8TgG-OU6VeV7vfl1A/0/da"><img src="http://feedads.g.doubleclick.net/~a/RLcthwbrGX8TgG-OU6VeV7vfl1A/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/RLcthwbrGX8TgG-OU6VeV7vfl1A/1/da"><img src="http://feedads.g.doubleclick.net/~a/RLcthwbrGX8TgG-OU6VeV7vfl1A/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=qDQCTb_mFN8:ut6c22ZkzYA:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=qDQCTb_mFN8:ut6c22ZkzYA:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/qDQCTb_mFN8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/05/23/taking-swtcocoa-and-miglayout-for-a-spin/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/05/23/taking-swtcocoa-and-miglayout-for-a-spin/</feedburner:origLink></item>
		<item>
		<title>Two IzPack use cases (Terracotta and Sun Grid Engine)</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/f7KtU0jTaCI/</link>
		<comments>http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/#comments</comments>
		<pubDate>Sun, 17 May 2009 18:27:16 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[IzPack]]></category>

		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=582</guid>
		<description><![CDATA[I recently became aware of two new great use cases of IzPack. I thought I would share them with you  
The first one is brought by Terracotta, the JVM clustering specialists. Download the cross-platform installer and you will get a nicely done IzPack-based installer.
The second one if from the friends at Sun Microsystems, as [...]]]></description>
			<content:encoded><![CDATA[<p>I recently became aware of two new great use cases of <a href="http://izpack.org/">IzPack</a>. I thought I would share them with you <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>The first one is brought by <a href="http://www.terracotta.org/">Terracotta</a>, the JVM clustering specialists. Download the cross-platform installer and you will get a nicely done IzPack-based installer.</p>
<p>The second one if from the friends at Sun Microsystems, as they built an impressive installer for <a href="http://wikis.sun.com/display/GridEngine/Home">Sun Grid Engine</a>. That&#8217;s a truly awesome one, as it exhibits lots of customizations (e.g., custom panels).</p>
<p>Here are some screenshots (the Sun Grid Engine ones come from their wiki site):</p>

<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/tc-1/' title='tc-1'><img src="http://jpz-log.info/wp-content/uploads/2009/05/tc-1-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/tc-2/' title='tc-2'><img src="http://jpz-log.info/wp-content/uploads/2009/05/tc-2-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/tc-3/' title='tc-3'><img src="http://jpz-log.info/wp-content/uploads/2009/05/tc-3-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/2b_license/' title='2b_license'><img src="http://jpz-log.info/wp-content/uploads/2009/05/2b_license-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/3_components/' title='3_components'><img src="http://jpz-log.info/wp-content/uploads/2009/05/3_components-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/4b_main/' title='4b_main'><img src="http://jpz-log.info/wp-content/uploads/2009/05/4b_main-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/5d_select/' title='5d_select'><img src="http://jpz-log.info/wp-content/uploads/2009/05/5d_select-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>
<a href='http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/8_result/' title='8_result'><img src="http://jpz-log.info/wp-content/uploads/2009/05/8_result-150x150.png" width="150" height="150" class="attachment-thumbnail" alt="" /></a>

<p>Shall need be, it proves once again that highly specific needs can be served with IzPack, an open and extensible platform for making cross-platform installers. With IzPack you are not constrained within the bounds of a rigid, so classical type of installer framework (I won&#8217;t give names, but hey, there is even an installers company that tries to pretend making opensource!).</p>
<p><strong>On a final note, do not forget that you can <a href="http://izpack.proservices.ponge.info/">get IzPack consulting, support and custom development from me</a> <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </strong></p>

<p><a href="http://feedads.g.doubleclick.net/~a/3X31WE4FoGiKRdEwoXeOMiVef94/0/da"><img src="http://feedads.g.doubleclick.net/~a/3X31WE4FoGiKRdEwoXeOMiVef94/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/3X31WE4FoGiKRdEwoXeOMiVef94/1/da"><img src="http://feedads.g.doubleclick.net/~a/3X31WE4FoGiKRdEwoXeOMiVef94/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=f7KtU0jTaCI:YA27L2RGqZ4:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=f7KtU0jTaCI:YA27L2RGqZ4:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/f7KtU0jTaCI" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/05/17/two-izpack-use-cases-terracotta-and-sun-grid-engine/</feedburner:origLink></item>
		<item>
		<title>What’s new in IzPack 4.3.0?</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/nKxngB0F7vs/</link>
		<comments>http://jpz-log.info/archives/2009/05/07/whats-new-in-izpack-430/#comments</comments>
		<pubDate>Thu, 07 May 2009 08:24:32 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[IzPack]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=577</guid>
		<description><![CDATA[IzPack 4.3.0 was released on April 21st 2009.
The present document contains the announcement materials and some highlights on the new features in this release.
About IzPack

IzPack is a one-stop solution for packaging, distributing and deploying applications. IzPack is opensource, released under the liberal Apache Software License 2.0.
It is fully cross-platform and generates a single installer. As [...]]]></description>
			<content:encoded><![CDATA[<p>IzPack 4.3.0 was released on April 21st 2009.</p>
<p>The present document contains the announcement materials and some highlights on the new features in this release.</p>
<h2>About IzPack</h2>
<p><img src="http://jpz-log.info/wp-content/uploads/2008/05/izpack-logo.png" alt="IzPack" title="IzPack" width="262" height="90" class="alignnone size-full wp-image-196" /></p>
<p>IzPack is a one-stop solution for packaging, distributing and deploying applications. IzPack is opensource, released under the liberal Apache Software License 2.0.</p>
<p>It is fully cross-platform and generates a single installer. As such, it is an alternative to native solutions such as platform-specific installers and package managers.</p>
<p>IzPack-generated installers only require a Java virtual machine to run.</p>
<p>Many companies and projects have been using IzPack over the years, including Sun Microsystems, JBoss/RedHat, the Scala language project, some ObjectWeb/OW2 projects, XWiki and many more.</p>
<h3>Downloading IzPack</h3>
<p>IzPack can be obtained free of charge from its website at <a href="http://izpack.org/">http://izpack.org/</a></p>
<h3>Getting professional services</h3>
<p>IzPack creator and project leader Julien Ponge offers paid professional services:</p>
<ul>
<li>one-time and subscription-based support,</li>
<li>consulting,</li>
<li>custom developments,</li>
<li>installer creation bootstrap.</li>
</ul>
<p>Do not hesitate to contact Julien and get more informations from <a href="http://izpack.proservices.ponge.info/">http://izpack.proservices.ponge.info/</a></p>
<p>Those services directly help in sustaining and improving IzPack.</p>
<h2>About this release</h2>
<p>This release is the result of a collective effort where our developers and contributors worked hand-in-hand to improve IzPack. Also, new developers have joined the project to bring further ideas and energy to the project.</p>
<p>About a hundred issues have been resolved in this release. The complete list along with JIRA issues can be reviewed at <a href="http://jira.codehaus.org/browse/IZPACK/fixforversion/14763">http://jira.codehaus.org/browse/IZPACK/fixforversion/14763</a></p>
<h2>New features highlights</h2>
<p>The release contains its usual set of bug fixes, small enhancements and documentation improvements. Each resolved issue is significant, however we cannot detail each of them. Instead, let us focus on some important new features in IzPack 4.3.0.</p>
<h3>Scripting support through the Apache Bean Scripting Framework</h3>
<p>IzPack provides installation, compilation and uninstallation events which can be intercepted by custom handlers. This is a common IzPack extension mechanism. As an example, IzPack itself provides such handlers for various tasks such as writing Windows registry entries during installation, and properly removing them during uninstallation.</p>
<p>This new feature allows such handlers to be implemented with a scripting language rather than Java classes. This makes them easier to develop, test and maintain in some contexts.</p>
<p>The Apache Bean Scripting Framework (see <a href="http://jakarta.apache.org/bsf/">http://jakarta.apache.org/bsf/</a>) supports a wide range of languages, including JavaScript, Groovy, Python, Ruby and more.</p>
<p>This feature was contributed by Matthew Inger.</p>
<p>See <a href="http://jira.codehaus.org/browse/IZPACK-240">http://jira.codehaus.org/browse/IZPACK-240</a></p>
<h3>Full console manual and automated installations</h3>
<p>This is probably the most long awaited feature in IzPack!</p>
<p>From the start, IzPack has provided the ability to record and replay installations on other systems. This is however very different from &#8220;real&#8221; console installations, which turn out to be useful in production scenario (e.g., installing a software on a remote system through a SSH connection that does not forward X11 instructions).</p>
<h3>Console installations can be manual (through text prompts) or even automated.</h3>
<p>This great work was contributed by Mounir El Hajj.<br />
See <a href="http://jira.codehaus.org/browse/IZPACK-320">http://jira.codehaus.org/browse/IZPACK-320</a></p>
<h3>Removal of NanoXML in favor of a javax.xml backend</h3>
<p>IzPack was first created in 2001, a time when there was no standard XML parser in the Java standard runtime (actually this was the very beginning of XML being all the rage!).</p>
<p>IzPack chose to embed a library called NanoXML as it was efficient, very small and it came along with a sensible API. We are now in 2009: there is a standard Java API for XML parsing in every Java runtime, and NanoXML has not been maintained for years. It also started to show some limitations and bugs, such as not supporting XML namespaces and more.</p>
<p>This release is free of NanoXML and instead uses a javax.xml backend. The changes to the existing IzPack code base and third party developments are insignificant as an adapter has been developed, carefully mimicking the NanoXML behavior and preserving the parts of its interface that we were using.</p>
<p>This work was made by Anthonin Bonnefoy and David Duponchel, 2 students from a french computer engineering school called ISIMA in the beautiful city of Clermont-Ferrand.</p>
<p>For the record, Anthonin and David have now joined the IzPack project as developers.</p>
<p>See:</p>
<p><a href="http://jira.codehaus.org/browse/IZPACK-280">http://jira.codehaus.org/browse/IZPACK-280</a>,<br />
<a href="http://jira.codehaus.org/browse/IZPACK-306">http://jira.codehaus.org/browse/IZPACK-306</a></p>
<h3>Ability to call Java classes before and after each panel</h3>
<p>IzPack panels have always been able to perform some custom validation. A typical example is the LicencePanel that vetoes the installation to progress as long as the user has not accepted the license agreement.</p>
<p>Florian Buehlmann has extended the validation mechanism so that a more generalized set of validations can be performed before and after a panel.</p>
<p>See <a href="http://jira.codehaus.org/browse/IZPACK-285">http://jira.codehaus.org/browse/IZPACK-285</a></p>
<h3>Privileges elevation improvements</h3>
<p>IzPack is able to perform privileges elevation on various operating systems, as otherwise some installations can fail due to insufficient user permissions.</p>
<p>IzPack 4.2.1 already brought some improvements in this area by allowing the elevation mechanism to be enabled only on certain operating systems (e.g., attempt an elevation only when run on Windows Vista or Mac OS X).</p>
<p>The detection of the current user privileges has been improved on Windows XP and Vista. Also, the uninstaller now avoids privileges elevation when the installer did not perform one. Finally, there was an issue when the installer was started from a Windows UNC path.</p>
<p>See:</p>
<p><a href="http://jira.codehaus.org/browse/IZPACK-217">http://jira.codehaus.org/browse/IZPACK-217</a>,<br />
<a href="http://jira.codehaus.org/browse/IZPACK-347">http://jira.codehaus.org/browse/IZPACK-347</a>,<br />
<a href="http://jira.codehaus.org/browse/IZPACK-308">http://jira.codehaus.org/browse/IZPACK-308</a></p>
<h3>Graphical reporting of launch-time errors</h3>
<p>When an installer is launched, some errors can be encountered before the graphical user interface is up. This results in the end-user not seeing an error nor seeing the installer showing up, unless it was started from a terminal.</p>
<p>Christian d&#8217;Heureuse contributed a fix for that, so that an error message shows up graphically.</p>
<p>See <a href="http://jira.codehaus.org/browse/IZPACK-318">http://jira.codehaus.org/browse/IZPACK-318</a></p>
<h3>AntActionListener improvement</h3>
<p>Up to now an AntActionListener required the build file to exist on the system to be use as the input to Ant. This limits the beforePack and beforePacks order to only those build files that preexist since at this point of the installation no files have been extracted from the installer packs. This also requires that build files exist on the system even if the Ant custom actions being executed are transient and not needed before or after the installation is performed.</p>
<p>The AntActionListener has been improved to reference a buildresource property that can specify an IzPack resource reference defined by the <resource> tag. This resource will be extracted to a temporary file on the system and used as the Ant build file for the AntActionListener. The temporary file will be removed when the installation completes. Using this mechanism, an embedded build file can be now used which does not need to exist on the system before or after the installation.</p>
<p>Note that either the buildfile or buildresource must be provided but not both.</p>
<p>See <a href="http://jira.codehaus.org/browse/IZPACK-158">http://jira.codehaus.org/browse/IZPACK-158</a></p>
<h3>Configuration of the uninstaller path</h3>
<p>It was possible to define a customized name for an uninstaller, but it was not possible to customized where it was written. Florian Buehlmann fixed that.</p>
<p>See <a href="http://jira.codehaus.org/browse/IZPACK-263">http://jira.codehaus.org/browse/IZPACK-263</a></p>
<h3>Compile-time variable substitutions</h3>
<p>Kjell Braden added the possibility to perform variables substitution in files at the installer compilation time.</p>
<p>See: <a href="http://jira.codehaus.org/browse/IZPACK-365">http://jira.codehaus.org/browse/IZPACK-365</a></p>
<h2>Greetings</h2>
<p>The IzPack team would like to thank its developers and contributors for having made this release possible! We would also like to thank our numerous and growing users worldwide for pushing us forward!</p>
<p>Other thanks go to:</p>
<ul>
<li>The Codehaus Foundation and especially Ben Walding: <a href="http://codehaus.org/">http://codehaus.org/</a></li>
<li>JetBrains for their amazing IntelliJ IDEA IDE: <a href="http://www.jetbrains.com/">http://www.jetbrains.com/</a></li>
<li>Atlassian for the tools that power some Codehaus services: <a href="http://www.atlassian.com/">http://www.atlassian.com/</a></li>
<li>Sun Microsystems, especially the Glassfish and IPS teams: <a href="http://www.sun.com/">http://www.sun.com/</a></li>
</ul>
<h2>Further links</h2>
<ul>
<li>IzPack website: <a href="http://izpack.org/">http://izpack.org/</a></li>
<li>Codehaus space: <a href="http://xircles.codehaus.org/projects/izpack/">http://xircles.codehaus.org/projects/izpack/</a></li>
<li>Mailing-lists: <a href="http://xircles.codehaus.org/projects/izpack/lists">http://xircles.codehaus.org/projects/izpack/lists</a></li>
<li>Confluence wiki: <a href="http://docs.codehaus.org/display/IZPACK">http://docs.codehaus.org/display/IZPACK</a></li>
<li>News feed: <a href="http://feeds.feedburner.com/IzPack">http://feeds.feedburner.com/IzPack</a></li>
<li>Subversion repository: <a href="http://svn.codehaus.org/izpack/">http://svn.codehaus.org/izpack/</a></li>
<li>Git repository (synchronized from svn): <a href="http://github.com/jponge/izpack/tree/master">http://github.com/jponge/izpack/tree/master</a></li>
<li>FishEye SVN browser: <a href="http://svn.izpack.codehaus.org/">http://svn.izpack.codehaus.org/</a></li>
<li>JIRA issues tracker: <a href="http://jira.codehaus.org/browse/IZPACK">http://jira.codehaus.org/browse/IZPACK</a></li>
</ul>

<p><a href="http://feedads.g.doubleclick.net/~a/cF3awFcAwSyanM4PeSbesXeDCEU/0/da"><img src="http://feedads.g.doubleclick.net/~a/cF3awFcAwSyanM4PeSbesXeDCEU/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/cF3awFcAwSyanM4PeSbesXeDCEU/1/da"><img src="http://feedads.g.doubleclick.net/~a/cF3awFcAwSyanM4PeSbesXeDCEU/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=nKxngB0F7vs:WLre_-87rng:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=nKxngB0F7vs:WLre_-87rng:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/nKxngB0F7vs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/05/07/whats-new-in-izpack-430/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/05/07/whats-new-in-izpack-430/</feedburner:origLink></item>
		<item>
		<title>IzPack 4.3.0 is out!</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/nfbGdrixtxY/</link>
		<comments>http://jpz-log.info/archives/2009/04/21/izpack-430-is-out/#comments</comments>
		<pubDate>Tue, 21 Apr 2009 09:27:34 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[IzPack]]></category>

		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=563</guid>
		<description><![CDATA[
I am very pleased to announce the immediate availability of IzPack 4.3.0!
About IzPack
IzPack is a one-stop solution for packaging, distributing and deploying applications. IzPack is opensource, released under the liberal Apache Software License 2.0.
It is fully cross-platform and generates a single installer. As such, it is
an alternative to native solutions such as platform-specific installers and [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://jpz-log.info/wp-content/uploads/2008/05/izpack-logo.png"><img src="http://jpz-log.info/wp-content/uploads/2008/05/izpack-logo.png" alt="IzPack" title="IzPack" width="262" height="90" class="alignnone size-full wp-image-196" /></a></p>
<p>I am very pleased to announce the immediate availability of IzPack 4.3.0!</p>
<p><strong>About IzPack</strong></p>
<p>IzPack is a one-stop solution for packaging, distributing and deploying applications. IzPack is opensource, released under the liberal Apache Software License 2.0.</p>
<p>It is fully cross-platform and generates a single installer. As such, it is<br />
an alternative to native solutions such as platform-specific installers and package managers.</p>
<p>IzPack-generated installers only require a Java virtual machine to run.</p>
<p>Many companies and projects have been using IzPack over the years, including Sun Microsystems, JBoss/RedHat, the Scala language project, some  ObjectWeb/OW2 projects, XWiki and many more.</p>
<p><strong>Downloading IzPack</strong></p>
<p>IzPack can be obtained free of charge from its website at <a  href="http://izpack.org/">http://izpack.org/</a></p>
<p><strong>Getting professional services</strong></p>
<p>IzPack creator and project leader Julien Ponge offers paid professional services:</p>
<ul>
<li>one-time and subscription-based support</li>
<li>consulting</li>
<li>custom developments</li>
<li>installer creation bootstrap.</li>
</ul>
<p>Do not hesitate to contact Julien and get more informations from <a  ref="http://izpack.proservices.ponge.info/">http://izpack.proservices.ponge.info/</a></p>
<p>Those services directly help in sustaining and improving IzPack.</p>
<p><strong>About this release</strong></p>
<p>This release is the result of a collective effort where our developers and contributors worked hand-in-hand to improve IzPack. Also, new developers have joined the project to bring further ideas and energy to the project.</p>
<p>About a hundred issues have been resolved in this release. The complete list along with JIRA issues can be reviewed at <a href="http://jira.codehaus.org/browse/IZPACK/fixforversion/14763">http://jira.codehaus.org/browse/IZPACK/fixforversion/14763</a></p>
<p><strong>New features highlights</strong></p>
<p>The release contains its usual set of bug fixes, small enhancements and documentation improvements. The new features include:</p>
<ul>
<li>Scripting support through the Apache Bean Scripting Framework</li>
<li>Full console manual and automated installations</li>
<li>Removal of NanoXML in favor of a javax.xml backend</li>
<li>Ability to call Java classes before and after each panel</li>
<li>Privileges elevation improvements</li>
<li>Graphical reporting of launch-time errors</li>
<li>AntActionListener improvement</li>
<li>Configuration of the uninstaller path</li>
<li>Compile-time variable substitutions</li>
</ul>
<p><strong>Greetings</strong></p>
<p>The IzPack team would like to thank its developers and contributors for having made this release possible! We would also like to thank our numerous and growing users worldwide for pushing us forward!</p>
<p>Other thanks go to:</p>
<ul>
<li>The Codehaus Foundation and especially Ben Walding: <a  href="http://codehaus.org/">http://codehaus.org/</a></li>
<li>JetBrains for their amazing IntelliJ IDEA IDE: <a  href="http://www.jetbrains.com/">http://www.jetbrains.com/</a></li>
<li>Atlassian for the tools that power some Codehaus services: <a  href="http://www.atlassian.com/">http://www.atlassian.com/</a></li>
<li>Sun Microsystems, especially the Glassfish and IPS teams: <a  href="http://www.sun.com/">http://www.sun.com/</a></li>
</ul>
<p><strong>Further links</strong></p>
<ul>
<li>IzPack website: <a  href="http://izpack.org/">http://izpack.org/</a></li>
<li>Codehaus space: <a href="http://xircles.codehaus.org/projects/izpack/">http://xircles.codehaus.org/projects/izpack/</a></li>
<li>Mailing-lists: <a  href="http://xircles.codehaus.org/projects/izpack/lists">http://xircles.codehaus.org/projects/izpack/lists</a></li>
<li>Confluence wiki: <a href="http://docs.codehaus.org/display/IZPACK">http://docs.codehaus.org/display/IZPACK</a></li>
<li>News feed: <a href="http://feeds.feedburner.com/IzPack">http://feeds.feedburner.com/IzPack</a></li>
<li>Subversion repository: <a href="http://svn.codehaus.org/izpack/">http://svn.codehaus.org/izpack/</a></li>
<li>Git repository (synchronized from svn): <a href="http://github.com/jponge/izpack/tree/master">http://github.com/jponge/izpack/tree/master</a></li>
<li>FishEye SVN browser: <a href="http://svn.izpack.codehaus.org/">http://svn.izpack.codehaus.org/</a></li>
<li>JIRA issues tracker: <a href="http://jira.codehaus.org/browse/IZPACK">http://jira.codehaus.org/browse/IZPACK</a></li>
</ul>

<p><a href="http://feedads.g.doubleclick.net/~a/van0ZYZIHBDZZbhSCRgGSP8exeY/0/da"><img src="http://feedads.g.doubleclick.net/~a/van0ZYZIHBDZZbhSCRgGSP8exeY/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/van0ZYZIHBDZZbhSCRgGSP8exeY/1/da"><img src="http://feedads.g.doubleclick.net/~a/van0ZYZIHBDZZbhSCRgGSP8exeY/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=nfbGdrixtxY:HOG4cXWZ0RY:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=nfbGdrixtxY:HOG4cXWZ0RY:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/nfbGdrixtxY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/04/21/izpack-430-is-out/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/04/21/izpack-430-is-out/</feedburner:origLink></item>
		<item>
		<title>A todo list on Google App Engine… Python</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/Pyjb467iSew/</link>
		<comments>http://jpz-log.info/archives/2009/04/20/a-todo-list-on-google-app-engine-python/#comments</comments>
		<pubDate>Mon, 20 Apr 2009 08:20:42 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[Fun]]></category>

		<category><![CDATA[Geeking]]></category>

		<category><![CDATA[Opinion]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=555</guid>
		<description><![CDATA[It seems like everyone is getting crazy those days with the availability of Java for Google App Engine. While this is certainly a great addition to the Google cloud computing offering, I remain a bit puzzled on what it means for Java. Indeed:

lots of libraries and frameworks need to be tweaked to run on GAE
there [...]]]></description>
			<content:encoded><![CDATA[<p>It seems like everyone is getting crazy those days with the availability of Java for Google App Engine. While this is certainly a great addition to the Google cloud computing offering, I remain a bit puzzled on what it means for Java. Indeed:</p>
<ul>
<li>lots of libraries and frameworks need to be tweaked to run on GAE</li>
<li>there is a whitelist for the classes that you can use, which means no threads, no static files for writing and so on</li>
<li>datastore entries are bound by a 1Mb limit, which means no big uploads in your applications</li>
<li>the effort to support specifications like <a href="http://java.sun.com/developer/technicalArticles/J2EE/jpa/">JPA</a> is great, yet I doubt it will be easy to port existing JPA-enabled applications over GAE as the persistence in GAE is not based on a relational model (which is not necessarily a bad idea by itself!).</li>
</ul>
<p>Should you care about GAE / Java? My take is that it is a nice cloud computing offering, but if you choose to use it then you should expect to develop your applications specifically for it. Making hybrid GAE / normal webapps is probably worth too many headaches <img src='http://jpz-log.info/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p>People should not forget that GAE first appeared with <a href="http://python.org/">Python</a>, a great language by itself. The GAE Python framework is quite simple to use, while the view rendering part is based on the elegant <a href="http://docs.djangoproject.com/en/dev/ref/templates/builtins/">Django templates</a>.</p>
<p>Just to break with the massive trend toward playing with GAE / Java, I wrote a stupid todo lists manager with the Python flavor:</p>
<ul>
<li>live at <a href="http://jpz-todolists.appspot.com/">http://jpz-todolists.appspot.com/</a> (works with your Google account)</li>
<li>code at <a href="http://github.com/jponge/pyappenginetodolist/tree/master">http://github.com/jponge/pyappenginetodolist/tree/master</a></li>
</ul>
<p>Building the application in Python was relatively simple and painless. The only point that annoyed me a bit is the handling of URL mappings, as you need to specify it in your <code>app.yaml</code> and also in your controller class, which sounds like breaking the <a href="http://en.wikipedia.org/wiki/Don't_repeat_yourself">DRY principle</a>.</p>
<p>The persisted model definition can&#8217;t be any simpler:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">class</span> TodoEntry<span style="color: black;">&#40;</span>db.<span style="color: black;">Model</span><span style="color: black;">&#41;</span>:
    <span style="color: #dc143c;">user</span> = db.<span style="color: black;">UserProperty</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
    text = db.<span style="color: black;">StringProperty</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span></pre></div></div>

<p><code>db.UserProperty()</code> allows to link with a Google Account.</p>
<p>Fetching one user todo entries is simple:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;">entries = db.<span style="color: black;">GqlQuery</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;SELECT * FROM TodoEntry WHERE user = :userid&quot;</span>, userid=<span style="color: #dc143c;">user</span><span style="color: black;">&#41;</span></pre></div></div>

<p>Handling the authentication is also very simple:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">def</span> authenticate<span style="color: black;">&#40;</span><span style="color: #008000;">self</span><span style="color: black;">&#41;</span>:
    <span style="color: #dc143c;">user</span> = users.<span style="color: black;">get_current_user</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
    <span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #ff7700;font-weight:bold;">not</span> <span style="color: #dc143c;">user</span>
        <span style="color: #008000;">self</span>.<span style="color: black;">redirect</span><span style="color: black;">&#40;</span>users.<span style="color: black;">create_login_url</span><span style="color: black;">&#40;</span><span style="color: #008000;">self</span>.<span style="color: black;">request</span>.<span style="color: black;">uri</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
    <span style="color: #ff7700;font-weight:bold;">else</span>:
        <span style="color: #ff7700;font-weight:bold;">return</span> <span style="color: #dc143c;">user</span></pre></div></div>

<p>One last excerpt: rendering a view through a Django template:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;">values = <span style="color: black;">&#123;</span>
    <span style="color: #483d8b;">'userid'</span>: <span style="color: #dc143c;">user</span>.<span style="color: black;">nickname</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>,
    <span style="color: #483d8b;">'entries'</span>: entries,
    <span style="color: #483d8b;">'logout_url'</span>: users.<span style="color: black;">create_logout_url</span><span style="color: black;">&#40;</span><span style="color: #008000;">self</span>.<span style="color: black;">request</span>.<span style="color: black;">uri</span><span style="color: black;">&#41;</span>
<span style="color: black;">&#125;</span>
&nbsp;
tpl = <span style="color: #dc143c;">os</span>.<span style="color: black;">path</span>.<span style="color: black;">join</span><span style="color: black;">&#40;</span><span style="color: #dc143c;">os</span>.<span style="color: black;">path</span>.<span style="color: black;">dirname</span><span style="color: black;">&#40;</span>__file__<span style="color: black;">&#41;</span>, <span style="color: #483d8b;">'todo.html'</span><span style="color: black;">&#41;</span>
<span style="color: #008000;">self</span>.<span style="color: black;">response</span>.<span style="color: black;">out</span>.<span style="color: black;">write</span><span style="color: black;">&#40;</span>template.<span style="color: black;">render</span><span style="color: black;">&#40;</span>tpl, values<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span></pre></div></div>

<p>Look at the code, it is quite straightforward and easy to understand, so if you already know Python, don&#8217;t forget that GAE / Python works just great too <img src='http://jpz-log.info/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>

<p><a href="http://feedads.g.doubleclick.net/~a/yBEXzzrbPAanUTLMOgtS7qAiGv8/0/da"><img src="http://feedads.g.doubleclick.net/~a/yBEXzzrbPAanUTLMOgtS7qAiGv8/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/yBEXzzrbPAanUTLMOgtS7qAiGv8/1/da"><img src="http://feedads.g.doubleclick.net/~a/yBEXzzrbPAanUTLMOgtS7qAiGv8/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=Pyjb467iSew:5nH2U7NHGRI:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=Pyjb467iSew:5nH2U7NHGRI:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/Pyjb467iSew" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/04/20/a-todo-list-on-google-app-engine-python/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/04/20/a-todo-list-on-google-app-engine-python/</feedburner:origLink></item>
		<item>
		<title>Scala and DSLs</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/p7zpalFP9Eg/</link>
		<comments>http://jpz-log.info/archives/2009/04/13/scala-and-dsls/#comments</comments>
		<pubDate>Mon, 13 Apr 2009 20:15:04 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[Geeking]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=547</guid>
		<description><![CDATA[Tonight I wrote something quick in Scala to make a small DSL (just for fun).
I started with a small Email class:

class Email&#40;name:String, address:String&#41; &#123;
&#160;
  def standardForm = name + &#34; &#60;&#34; + address + &#34;&#62;&#34;
&#160;
  override def toString = this.standardForm
&#160;
&#125;

which is really stupid: it wraps a name along with an email address, and [...]]]></description>
			<content:encoded><![CDATA[<p>Tonight I wrote something quick in <a href="http://scala-lang.org/">Scala</a> to make a small DSL (just for fun).</p>
<p>I started with a small <code>Email</code> class:</p>

<div class="wp_syntax"><div class="code"><pre class="scala" style="font-family:monospace;"><span style="color: #0000ff; font-weight: bold;">class</span> Email<span style="color: #F78811;">&#40;</span>name<span style="color: #000080;">:</span>String, address<span style="color: #000080;">:</span>String<span style="color: #F78811;">&#41;</span> <span style="color: #F78811;">&#123;</span>
&nbsp;
  <span style="color: #0000ff; font-weight: bold;">def</span> standardForm <span style="color: #000080;">=</span> name + <span style="color: #6666FF;">&quot; &lt;&quot;</span> + address + <span style="color: #6666FF;">&quot;&gt;&quot;</span>
&nbsp;
  <span style="color: #0000ff; font-weight: bold;">override</span> <span style="color: #0000ff; font-weight: bold;">def</span> toString <span style="color: #000080;">=</span> <span style="color: #0000ff; font-weight: bold;">this</span>.<span style="color: #000000;">standardForm</span>
&nbsp;
<span style="color: #F78811;">&#125;</span></pre></div></div>

<p>which is really stupid: it wraps a name along with an email address, and it adds a convenient textual output form.</p>
<p>Now I would like to be able to write something like:</p>

<div class="wp_syntax"><div class="code"><pre class="scala" style="font-family:monospace;"><span style="color: #0000ff; font-weight: bold;">val</span> me <span style="color: #000080;">=</span> <span style="color: #6666FF;">&quot;Julien Ponge&quot;</span> is <span style="color: #6666FF;">&quot;julien&quot;</span> at <span style="color: #6666FF;">&quot;gmail.com&quot;</span>
println<span style="color: #F78811;">&#40;</span>me<span style="color: #F78811;">&#41;</span></pre></div></div>

<p>To do that I wrote a simple builder:</p>

<div class="wp_syntax"><div class="code"><pre class="scala" style="font-family:monospace;">&nbsp;
<span style="color: #0000ff; font-weight: bold;">class</span> EmailBuilder<span style="color: #F78811;">&#40;</span>name<span style="color: #000080;">:</span>String<span style="color: #F78811;">&#41;</span> <span style="color: #F78811;">&#123;</span>
&nbsp;
  <span style="color: #0000ff; font-weight: bold;">var</span> id<span style="color: #000080;">:</span>String <span style="color: #000080;">=</span> <span style="color: #6666FF;">&quot;&quot;</span>
&nbsp;
  <span style="color: #0000ff; font-weight: bold;">def</span> is<span style="color: #F78811;">&#40;</span>str<span style="color: #000080;">:</span>String<span style="color: #F78811;">&#41;</span><span style="color: #000080;">:</span>EmailBuilder <span style="color: #000080;">=</span> <span style="color: #F78811;">&#123;</span>
    id <span style="color: #000080;">=</span> str
    <span style="color: #0000ff; font-weight: bold;">this</span>
  <span style="color: #F78811;">&#125;</span>
&nbsp;
  <span style="color: #0000ff; font-weight: bold;">def</span> at<span style="color: #F78811;">&#40;</span>str<span style="color: #000080;">:</span>String<span style="color: #F78811;">&#41;</span><span style="color: #000080;">:</span>Email <span style="color: #000080;">=</span> <span style="color: #F78811;">&#123;</span>
    <span style="color: #0000ff; font-weight: bold;">new</span> Email<span style="color: #F78811;">&#40;</span>name, id + <span style="color: #6666FF;">&quot;@&quot;</span> + str<span style="color: #F78811;">&#41;</span>
  <span style="color: #F78811;">&#125;</span>
&nbsp;
<span style="color: #F78811;">&#125;</span></pre></div></div>

<p>then an implicit conversion function:</p>

<div class="wp_syntax"><div class="code"><pre class="scala" style="font-family:monospace;"><span style="color: #0000ff; font-weight: bold;">implicit</span> <span style="color: #0000ff; font-weight: bold;">def</span> emailBuilder<span style="color: #F78811;">&#40;</span>name<span style="color: #000080;">:</span>String<span style="color: #F78811;">&#41;</span><span style="color: #000080;">:</span>EmailBuilder <span style="color: #000080;">=</span> <span style="color: #0000ff; font-weight: bold;">new</span> EmailBuilder<span style="color: #F78811;">&#40;</span>name<span style="color: #F78811;">&#41;</span></pre></div></div>

<p>And that&#8217;s it.</p>
<p>You should always learn new languages: they are all worth something great! Be polyglot, seriously.</p>
<p>By the way I heard that some of the Scala features are coming to the next major version of <a href="http://groovy.codehaus.org/">Groovy</a>, which is going to be exciting!</p>

<p><a href="http://feedads.g.doubleclick.net/~a/2NPun1CCKR7ZjiaShTKsugqjGq4/0/da"><img src="http://feedads.g.doubleclick.net/~a/2NPun1CCKR7ZjiaShTKsugqjGq4/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/2NPun1CCKR7ZjiaShTKsugqjGq4/1/da"><img src="http://feedads.g.doubleclick.net/~a/2NPun1CCKR7ZjiaShTKsugqjGq4/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=p7zpalFP9Eg:utdrZ91idwM:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=p7zpalFP9Eg:utdrZ91idwM:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/p7zpalFP9Eg" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/04/13/scala-and-dsls/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/04/13/scala-and-dsls/</feedburner:origLink></item>
		<item>
		<title>IzPack 4.3.0-rc2 released</title>
		<link>http://feedproxy.google.com/~r/JPzLog/~3/cL8Qi6W1GDY/</link>
		<comments>http://jpz-log.info/archives/2009/04/10/izpack-430-rc2-released/#comments</comments>
		<pubDate>Fri, 10 Apr 2009 08:00:41 +0000</pubDate>
		<dc:creator>jponge</dc:creator>
		
		<category><![CDATA[English]]></category>

		<category><![CDATA[IzPack]]></category>

		<guid isPermaLink="false">http://jpz-log.info/?p=541</guid>
		<description><![CDATA[See the offcial news.
We need you to:

download it
report any outstanding issue.

The full list of changes is available from our JIRA tracker.
Thanks for testing!
]]></description>
			<content:encoded><![CDATA[<p><a href="http://docs.codehaus.org/display/IZPACK/2009/04/10/IzPack+4.3.0-rc2">See the offcial news.</a></p>
<p>We need you to:</p>
<ul>
<li><a href="http://snapshots.dist.codehaus.org/izpack/IzPack-install-4.3.0-rc2.jar">download it</a></li>
<li><a href="http://jira.codehaus.org/browse/IZPACK">report any outstanding issue</a>.</li>
</ul>
<p>The full list of changes is<a href="http://jira.codehaus.org/browse/IZPACK/fixforversion/14763"> available from our JIRA tracker</a>.</p>
<p>Thanks for testing!</p>

<p><a href="http://feedads.g.doubleclick.net/~a/bvdYgtlCuSSiDLLk4GxpOIOInOQ/0/da"><img src="http://feedads.g.doubleclick.net/~a/bvdYgtlCuSSiDLLk4GxpOIOInOQ/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/bvdYgtlCuSSiDLLk4GxpOIOInOQ/1/da"><img src="http://feedads.g.doubleclick.net/~a/bvdYgtlCuSSiDLLk4GxpOIOInOQ/1/di" border="0" ismap="true"></img></a></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/JPzLog?a=cL8Qi6W1GDY:U1SqbxIL4ZY:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/JPzLog?i=cL8Qi6W1GDY:U1SqbxIL4ZY:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/JPzLog/~4/cL8Qi6W1GDY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://jpz-log.info/archives/2009/04/10/izpack-430-rc2-released/feed/</wfw:commentRss>
		<feedburner:origLink>http://jpz-log.info/archives/2009/04/10/izpack-430-rc2-released/</feedburner:origLink></item>
	</channel>
</rss>
