<?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:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>maxheapsize.com</title>
	
	<link>http://maxheapsize.com</link>
	<description>Oliver Wehrens on Programming and Agile</description>
	<lastBuildDate>Thu, 29 Jul 2010 10:53:00 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</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" type="application/rss+xml" href="http://feeds.feedburner.com/maxheapsizecom" /><feedburner:info uri="maxheapsizecom" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Spring 3 MVC, Ajax and jQuery Magic (or better: simplicity)</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/DLRTd06uvkE/</link>
		<comments>http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/#comments</comments>
		<pubDate>Tue, 20 Jul 2010 04:00:09 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[mvc]]></category>
		<category><![CDATA[spring 3]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=595</guid>
		<description><![CDATA[
			
				
			
		
I&#8217;m playing around with some web frameworks lately and to see what&#8217;s in store with Spring 3 MVC (never did too much with it) I gave it a try to see how it handles Ajax. According to ajax simplification announcement it should be possible to get up and running in (almost) no time.
We will do [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F07%2F20%2Fspring-3-mvc-ajax-and-jquery-magic-or-better-simplicity%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F07%2F20%2Fspring-3-mvc-ajax-and-jquery-magic-or-better-simplicity%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p>I&#8217;m playing around with some web frameworks lately and to see what&#8217;s in store with Spring 3 MVC (never did too much with it) I gave it a try to see how it handles Ajax. According to <a href="http://blog.springsource.com/2010/01/25/ajax-simplifications-in-spring-3-0/">ajax simplification announcement</a> it should be possible to get up and running in (almost) no time.</p>
<p>We will do a simple web application which will show the current time via Ajax. </p>
<p>The directory layout (using maven) should look like this:</p>
<div class="wp-caption aligncenter" style="width: 339px"><img alt="Directory Layout" src="http://maxheapsize.com/static/Spring3MVCFiles.png" title="Ajax result" width="329" height="308" /><p class="wp-caption-text">Directory Layout</p></div>
<pre class="brush: xml;">
&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;web-app xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
	xmlns=&quot;http://java.sun.com/xml/ns/javaee&quot;
	xmlns:web=&quot;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd&quot;
	xsi:schemaLocation=&quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd&quot;
	id=&quot;WebApp_ID&quot; version=&quot;2.5&quot;&gt;
	&lt;display-name&gt;Spring3MVC&lt;/display-name&gt;
	&lt;welcome-file-list&gt;
		&lt;welcome-file&gt;index.jsp&lt;/welcome-file&gt;
	&lt;/welcome-file-list&gt;

	&lt;servlet&gt;
		&lt;servlet-name&gt;spring&lt;/servlet-name&gt;
		&lt;servlet-class&gt;
			org.springframework.web.servlet.DispatcherServlet
		&lt;/servlet-class&gt;
		&lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
	&lt;/servlet&gt;
	&lt;servlet-mapping&gt;
		&lt;servlet-name&gt;spring&lt;/servlet-name&gt;
		&lt;url-pattern&gt;*.html&lt;/url-pattern&gt;
	&lt;/servlet-mapping&gt;
&lt;/web-app&gt;
</pre>
<p>The web.xml holds no secrets. The Dispatcher servlet is defined and it should react on everything *.html.</p>
<p>Since we named our Servlet &#8217;spring&#8217; we need to add a servlet configuration for that. It goes in WEB-INF as well.</p>
<pre class="brush: xml;">
&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;beans xmlns=&quot;http://www.springframework.org/schema/beans&quot;
	xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
	xmlns:p=&quot;http://www.springframework.org/schema/p&quot;
	xmlns:context=&quot;http://www.springframework.org/schema/context&quot;
	xsi:schemaLocation=&quot;http://www.springframework.org/schema/beans
		http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
		http://www.springframework.org/schema/context
		http://www.springframework.org/schema/context/spring-context-3.0.xsd&quot;&gt;

	&lt;context:component-scan base-package=&quot;com.maxheapsize.springmvc3.controller&quot; /&gt;

	&lt;bean id=&quot;viewResolver&quot;
		class=&quot;org.springframework.web.servlet.view.UrlBasedViewResolver&quot;&gt;
		&lt;property name=&quot;viewClass&quot; value=&quot;org.springframework.web.servlet.view.JstlView&quot; /&gt;
		&lt;property name=&quot;prefix&quot; value=&quot;/WEB-INF/jsp/&quot; /&gt;
		&lt;property name=&quot;suffix&quot; value=&quot;.jsp&quot; /&gt;
	&lt;/bean&gt;
&lt;/beans&gt;
</pre>
<p>It uses the component scanning feature of spring and instructs spring to check the package &#8216;com.maxheapsize.springmvc3.controller&#8217; for controllers. Furthermore a url based view resolver is defined which uses Jstl and looks into /WEB-INF/jsp for jsp with the ending &#8216;.jsp&#8217;. </p>
<p>In  WEB-INF/jsp/hello.jsp we define a jQuery snippet for the Ajax request and provide a button which we should push if we want to know the time.</p>
<pre class="brush: xml;">
&lt;jsp:useBean id=&quot;message&quot; scope=&quot;request&quot; type=&quot;java.lang.String&quot;/&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;title&gt;Spring MVC Ajax Demo&lt;/title&gt;
  &lt;script type=&quot;text/javascript&quot; src=&quot;scripts/jquery.js&quot;&gt;&lt;/script&gt;
  &lt;script type=&quot;text/javascript&quot;&gt;
    function doAjax() {
      $.ajax({
        url: 'time.html',
        data: ({name : &quot;me&quot;}),
        success: function(data) {
          $('#time').html(data);
        }
      });
    }
  &lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
${message}
&lt;button id=&quot;demo&quot; onclick=&quot;doAjax()&quot; title=&quot;Button&quot;&gt;Get the time!&lt;/button&gt;
&lt;div id=&quot;time&quot;&gt;
&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>How does Spring now know which classes or methods to call? Here comes the nice part about it.</p>
<pre class="brush: java;">
package com.maxheapsize.springmvc3.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView;
import java.util.Date;

@Controller
public class HelloWorldController {

  @RequestMapping(&quot;/hello&quot;)
  public ModelAndView helloWorld() {
    return new ModelAndView(&quot;hello&quot;, &quot;message&quot;, &quot;Spring MVC Demo&quot;);
  }

  @RequestMapping(value = &quot;/time&quot;, method = RequestMethod.GET)
  public @ResponseBody String getTime(@RequestParam String name) {
    String result = &quot;Time for &quot; + name + &quot; is &quot; + new Date().toString();
    return result;
  }
}
</pre>
<p>The RequestMappings define the Url&#8217;s which can be called to reach that code. So the helloWorld method is available with &#8216;hello.html&#8217; in the web app. Why hello.html and not just hello ? Because we said so in the web.xml. I included a sample message which will be shown at the web  page when this method is called.</p>
<p> If you now push the button on the webpage, &#8216;time.html&#8217; with a parameter &#8216;name&#8217; is called. This will go directly to the second method. Spring will also check if a string parameter &#8216;name&#8217; (@RequestParam) is present in the original request. The @ResponseBody annotation  indicates that a method return value should be bound to the web response body.</p>
<p>The result will be returned and shown in the webpage.</p>
<div class="wp-caption aligncenter" style="width: 564px"><img alt="Ajax Result" src="http://maxheapsize.com/static/Spring3MVCAjax.png" title="Ajax result" width="554" height="83" /><p class="wp-caption-text">Ajax Result</p></div>
<p>Overall this is a pretty nice integration. I tend to use Spring for many projects and this makes it even easier to write some nice web apps in it. If you have a single page application and all you do is sending ajax request back and forth this might be a solution. </p>
<p><strong>JSON response Update</strong></p>
<p>To get a JSON response from your Controller you need to:</p>
<ol>
<li>Make sure the jackson mapper is present in your classpath. Maven users use:
<pre class="brush: xml;">
    &lt;dependency&gt;
      &lt;groupId&gt;org.codehaus.jackson&lt;/groupId&gt;
      &lt;artifactId&gt;jackson-mapper-asl&lt;/artifactId&gt;
      &lt;version&gt;1.5.3&lt;/version&gt;
    &lt;/dependency&gt;
</pre>
<p>in their pom.xml.
</li>
<li>MySimpleDataObject is a Pojo</li>
<li>The method you are calling has a signature like:
<pre class="brush: java;">
@RequestMapping(value = &quot;/demo&quot;, method= RequestMethod.GET)
public @ResponseBody MySimpleDataObject doSomething(@RequestParam name, @RequestParam email)
</pre>
</li>
<li>You are returning MySimpleDataObject at the end</li>
<li>Your calling javascript looks like this:
<pre class="brush: jscript;">
jQuery.getJSON(&quot;demo.html&quot;, {name: name, email: email}, function (data) {
        alert(data.someValueInMySimpleDataObject);
      });
</pre>
</li>
</ol>
<p>See also <a href="http://rwehner.wordpress.com/2010/06/09/2-ways-to-create-json-response-for-ajax-request-in-spring3/">Ralf&#8217;s post about Json and Spring MVC</a>. </p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=595&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29&amp;url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;bm_description=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/&amp;title=Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Spring+3+MVC%2C+Ajax+and+jQuery+Magic+%28or+better%3A+simplicity%29+@+http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/DLRTd06uvkE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/07/20/spring-3-mvc-ajax-and-jquery-magic-or-better-simplicity/</feedburner:origLink></item>
		<item>
		<title>Busy Programmers Guide on where to buy eBooks</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/oYSe8J_UIRA/</link>
		<comments>http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/#comments</comments>
		<pubDate>Sat, 05 Jun 2010 21:00:20 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[ebook]]></category>
		<category><![CDATA[epub]]></category>
		<category><![CDATA[kindle]]></category>
		<category><![CDATA[pdf]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=557</guid>
		<description><![CDATA[
			
				
			
		
Every Programmer needs to read books. Usually you would get some packages from Amazon (or your favorite retailer) and read through them.
Now with devices like the Kindle and iPad (and Nook and&#8230;) things will change. No more carrying around a couple of hundred pages of paper. Only some Megabytes on Gigabytes of storage. The displays [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F06%2F05%2Fbusy-programmers-guide-on-where-to-buy-ebooks%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F06%2F05%2Fbusy-programmers-guide-on-where-to-buy-ebooks%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p>Every Programmer needs to read books. Usually you would get some packages from Amazon (or your favorite retailer) and read through them.<br />
Now with devices like the Kindle and iPad (and Nook and&#8230;) things will change. No more carrying around a couple of hundred pages of paper. Only some Megabytes on Gigabytes of storage. The displays nowadays are good enough and the battery is not a problem for the most part.</p>
<p>Now the tricky part, you want your books in a format which you can read on many devices. The obvious candidates are:</p>
<ul>
<li><strong>PDF</strong> : Lots of books are available in pdf, be sure not to get DRM PDF. Not all reader software can show this.</li>
<li><strong>Kindle (.azw)</strong> : The Kindle Software is available for many devices (iPad, PC, Mac and of course Kindle devices).</li>
<li><strong>mobi</strong> : Some stuff is available in .mobi as well.</li>
<li><strong>ePub</strong> : This is also wide spread. A DRM&#8217;d version is also available. So make sure your reader is able to handle that.</li>
</ul>
<p>The best choice is of course to get non protected (read non-drm) books. To me pdf, epub and azw (I know, drm) all look nice. It is just a question of your reading device. </p>
<p>Formats are important but and the end, where do I get my books?</p>
<p>I picked a few publisher and looked on what they provide. Amazon is a different thing anyway. I compare the prices to their Kindle format.</p>
<style>
td { width: 80px; background #ccc; text-align: center }
th { text-align: center }
table { border: 1px dotted black; padding: 10px; }
</style>
<p><b><a href="http://manning.com/catalog/mobile/">Manning</a></b> &#8211; <a href="http://www.manning.com/bibeault/">jQuery in Action</a></p>
<table>
<tr>
<th></th>
<th>Print Book</th>
<th>eBook</th>
<th>Amazon</th>
<th>Kindle</th>
</tr>
<tr>
<td><img src="http://ecx.images-amazon.com/images/I/51srSzNztpL._SL160_PIsitb-sticker-arrow-dp,TopRight,12,-18_SH30_OU01_AA115_.jpg"></td>
<td>$39.99 (+ PDF)</td>
<td style="background: #8BC95A">$24.55 (.epub, pdf, .mobi)</td>
<td >$29.69</td>
<td >Could not find Manning titles for Kindle</td>
</table>
<p><b><a href="http://www.wrox.com/WileyCDA/Section/All-Titles-Books-Ebooks-for-Programmers-ASP-NET-C-Javascript-More.id-105077.html">Wrox</a></b> &#8211; <a href="http://www.wrox.com/WileyCDA/WroxTitle/Professional-XMPP-Programming-with-JavaScript-and-jQuery.productCd-0470540710.html">Professional XMPP Programming with JavaScript and jQuery</a></p>
<table>
<tr>
<th></th>
<th>Print Book</th>
<th>eBook</th>
<th>Amazon</th>
<th>Kindle</th>
</tr>
<tr>
<td><img src="http://ecx.images-amazon.com/images/I/51zBSAaHI8L._SL160_AA115_.jpg"></td>
<td>$49.99</td>
<td>$49.99 (pdf, could be DRM)</td>
<td >$31.49</td>
<td style="background: #8BC95A">$19.54</td>
</table>
<p><b><a href="http://oreilly.com/ebooks/">OReilly</a></b> &#8211; <a href="http://oreilly.com/catalog/9780596809485/">97 Things Every Programmer Should Know</a></p>
<table>
<tr>
<th></th>
<th>Print Book</th>
<th>eBook</th>
<th>Amazon</th>
<th>Kindle</th>
</tr>
<tr>
<td><img src="http://ecx.images-amazon.com/images/I/51uSFVY7zjL._SL160_PIsitb-sticker-arrow-dp,TopRight,12,-18_SH30_OU01_AA115_.jpg"></td>
<td>$29.99 ($32.99 Book + eBook)</td>
<td>$23.99 (Android, Mobi, PDF, ePub) </td>
<td >$19.79</td>
<td style="background: #8BC95A">$18.85</td>
</table>
<p><b><a href="http://apress.com/ecommerce/ebookshop">APress</a></b> &#8211; <a href="http://apress.com/book/view/1430219483">Coders at Work</a></p>
<table>
<tr>
<th></th>
<th>Print Book</th>
<th>eBook</th>
<th>Amazon</th>
<th>Kindle</th>
</tr>
<tr>
<td><img src="http://ecx.images-amazon.com/images/I/51DEnAtKzBL._SL160_PIsitb-sticker-arrow-dp,TopRight,12,-18_SH30_OU01_AA115_.jpg"></td>
<td>$29.99</td>
<td>$20.99 (pdf) </td>
<td style="background: #8BC95A">$18.85</td>
<td>$19.79</td>
</table>
<p><b><a href="https://www.packtpub.com/">Packt Publishing</a></b> &#8211; <a href="https://www.packtpub.com/solr-1-4-enterprise-search-server/book">Solr 1.4 Enterprise Search Server</a></p>
<table>
<tr>
<th></th>
<th>Print Book</th>
<th>eBook</th>
<th>Amazon</th>
<th>Kindle</th>
</tr>
<tr>
<td><img src="http://ecx.images-amazon.com/images/I/5141rH49WML._SL160_AA115_.jpg"></td>
<td>$40.49</td>
<td style="background: #8BC95A">$30.59 (pdf)</td>
<td >$35.39</td>
<td> Could not find any Packt titles for Kindle</td>
</table>
<p><b><a href="http://pragprog.com/">Pragmatic Bookshelf</a></b> &#8211; <a href="http://pragprog.com/titles/vsscala/programming-scala">Programming Scala: Tackle Multi-Core Complexity on the JVM</a></p>
<table>
<tr>
<th></th>
<th>Print Book</th>
<th>eBook</th>
<th>Amazon</th>
<th>Kindle</th>
</tr>
<tr>
<td><img src="http://ecx.images-amazon.com/images/I/51hfd66G1pL._SL160_AA115_.jpg"></td>
<td>$34.95 ($43.75 book + pdf,mobi,epub)</td>
<td style="background: #8BC95A">$22.00 (pdf,mobi,epub)</td>
<td >$23.07</td>
<td> Could not find any titles for Kindle</td>
</table>
<h3>Conclusion:</h3>
<p>Amazon shines, if they can offer eBooks there are priced very low, sometimes even the printed book is cheaper then the publisher eBook. If you can cope with Amazons format, a Kindle (or a Kindle app) is the way to go. Instant download, sharing between devices, very nice. I can now carry around dozens of books which I get for very cheap.<br />
<a href="http://twitter.com/manningbooks">Mannings</a> and <a href="http://twitter.com/wrox">Wrox</a> have Twitter accounts where they announce good discounts on printed and electronic books. Worth to checkout. APress eBooks are always 30% cheaper as the cover price of the printed one.<br />
Most of the publishers do have an extensive part of their books available as eBoooks.</p>
<p>Getting the eBooks is especially nice for folks living outside the US, e.g. &#8216;97 Things Every Programmer Should Know&#8217; is listed for about $27 at Amazon Germany. So I save about 40%. I will buy more books now since they are now much cheaper and more accessible to me.</p>
<p>My reader is an iPad with iBooks for epubs, the Kindle app for Amazon&#8217;s selection and GoodReader for Pdf&#8217;s. </p>
<p>Does anybody have good or bad experience with eBooks? </p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=557&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Busy+Programmers+Guide+on+where+to+buy+eBooks&amp;url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;bm_description=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/&amp;title=Busy+Programmers+Guide+on+where+to+buy+eBooks" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Busy+Programmers+Guide+on+where+to+buy+eBooks+@+http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/oYSe8J_UIRA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/06/05/busy-programmers-guide-on-where-to-buy-ebooks/</feedburner:origLink></item>
		<item>
		<title>How to detect if your server is down when making jQuery Ajax calls</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/en5kW7AOPbU/</link>
		<comments>http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/#comments</comments>
		<pubDate>Mon, 26 Apr 2010 19:19:33 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Web]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=546</guid>
		<description><![CDATA[
			
				
			
		
If you developed an ajax rich web application, maybe even a single page interface, you want to make sure that the user gets notified if the server is not reachable anymore. This happens either if the it goes down or the client loses its network connection.
Depending on your code the application can run for a [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F04%2F26%2Fhow-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F04%2F26%2Fhow-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p>If you developed an <strong>ajax rich web application</strong>, maybe even a single page interface, you want to make sure that the user gets <strong>notified</strong> if the server is <strong>not reachable</strong> anymore. This happens either if the it goes down or the client loses its network connection.<br />
Depending on your code the application can run for a while and the <strong>user is confused</strong> about missing interactivity.</p>
<p>So how do you detect this? jQuery offers an error callback if something with the call goes wrong. </p>
<pre class="brush: jscript;">
window.setInterval(function() {
$.ajax({
   type: 'GET',
   url: 'http://www.myapp.com/heartbeat',
   success: function(data, textStatus, XMLHttpRequest) {},
   error: function(XMLHttpRequest, textStatus, errorThrown) {
      alert('Failure');
    }
  });
}, 2000);
</pre>
<p>Unfortunately this does not work for a server which is down and if you are using a debugger like Firebug you will see that these calls have the status aborted. It turns out that if the <strong>server goes away</strong> jQuery will still execute the <strong>success callback</strong>. So how do you know that the server died?</p>
<p>I changed the response of the <strong>heartbeat</strong> query to contain some simple string like &#8216;alive&#8217;.  In the success callback I just check if the data contains this string. If it does not, I know that I do have a problem and I need to make sure that the user can&#8217;t do anything anymore.</p>
<p>I use the <a href='http://jquery.malsup.com/block/'>jQuery plugin uiBlock</a> to block every interaction and show a nice little message. Check out the <a href="http://jquery.malsup.com/block/#demos">uiBlock demos</a>.</p>
<pre class="brush: jscript;">
var uiBlocked = false;

window.setInterval(function() {
    $.ajax({
      cache: false,
      type: 'GET',
      url: '/mywebapp/alive.txt',
      timeout: 1000,
      success: function(data, textStatus, XMLHttpRequest) {
        if (data != 'alive') {
          if (uiBlocked == false) {
            uiBlocked = true;
            $.blockUI({
              message: &quot;I'm trying to connect to the server.&quot;,
              css: {
                border: 'none',
                padding: '15px',
                backgroundColor: '#000',
                '-webkit-border-radius': '10px',
                '-moz-border-radius': '10px',
                opacity: .5,
                color: '#fff'
              } });
          }
        } else {
          if (uiBlocked == true) {
            uiBlocked = false;
            $.unblockUI();
          }
        }
      }
    })

  }, 2000);
</pre>
<p>This code will check the server every 2 seconds and will<strong> block the UI</strong> when the server is not reachable and will <strong>come back up</strong> if the connection is <strong>alive</strong> again. Depending on your scenario (intranet/internet) you can change the interval for checking the connection.</p>
<p>This took me a couple of hours to get to this point and I thought it might be worth sharing. It seems a bit hacky but it works. What do you think?</p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=546&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls&amp;url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;bm_description=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/&amp;title=How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+How+to+detect+if+your+server+is+down+when+making+jQuery+Ajax+calls+@+http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/en5kW7AOPbU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/04/26/how-to-detect-if-your-server-is-down-when-making-jquery-ajax-calls/</feedburner:origLink></item>
		<item>
		<title>Lightweight Web Prototyping for the Framework loving (Java) Developer</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/P1JG91zYXuI/</link>
		<comments>http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/#comments</comments>
		<pubDate>Tue, 20 Apr 2010 13:00:53 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[prototype]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=532</guid>
		<description><![CDATA[
			
				
			
		
A couple of month ago I had an idea for a small web app. But what does it take to do it ? Do you start with the back end or the front end (read server or client side) ? Typically I would start at the back end, get the domain right and then see [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F04%2F20%2Flightweight-web-prototyping-for-the-framework-loving-java-developer%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F04%2F20%2Flightweight-web-prototyping-for-the-framework-loving-java-developer%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><a href="http://www.flickr.com/photos/istylr/3777635804/sizes/s/"><img class="alignleft" src="http://farm3.static.flickr.com/2562/3777635804_babcd16f90_m.jpg" title="© iStylr @ flickr"  /></a>A couple of month ago I had an idea for a small web app. But what does it take to do it ? Do you start with the back end or the front end (read server or client side) ? Typically I would start at the back end, get the domain right and then see how I can fit the UI in. If a programmer starts this way you end with the typical &#8216;the programmer did the GUI&#8217; scenario. That&#8217;s not really what I wanted. Don&#8217;t think too much about the domain, just see what the needs of the end user are and get the UI done (right). </p>
<h3>Trying frameworks &#8230;</h3>
<p>But there you go, being a framework loving web developer, how do you do the UI, or better, in what technology? Among other I tried  <a href="https://javaserverfaces.dev.java.net/">JSF 2</a> and I thought it&#8217;s cool. After a couple of hours I realized that this will slow me down. Fiddling with different ideas and concepts I just could not do that with JSF right away. I would have to write my own components. This is supposed to be very easy but still too much waste when I&#8217;m not sure if I even will use this.</p>
<h3> Trying paper&#8230; </h3>
<p>Next I started very basic and did some drawings. While this is all nice (I did it on my white board, I strongly recommend to do this on something you can erase) it turns out I had no idea on how to realize that in Html. I knew this must be possible somehow today but I had no idea what does it take to implement things like drag and drop, box scrolling, reordering and more. Nice thing I build on <a href="http://www.raincreativelab.com/paperbrowser/">paper</a>&#8230;but can I do it ?</p>
<h3>The solution</h3>
<p>What if I now combine those two approaches ? I needed some lightweight web framework, easy to learn (maybe one I already know) with  quick turn around. After looking around for a couple of hours I came up with <a href="http://www.w3.org/TR/html5/">Html</a> and <a href="http://jquery.com/">jQuery</a>. </p>
<p>I have some knowledge in Html and Css but I never did anything in Javascript or jQuery. So there is something new to learn. Since this was on my agenda anyway and I already bought Mannings <a href="http://www.manning.com/bibeault/">jQuery in Action</a> book in December I went this route. I hoped that adding jQuery into the page would give me some interactivity to the otherwise static Html page.</p>
<p> It turns out, it was the best choice. I came up with at least three completely different designs in a matter of evenings, got them to a working stage and could &#8216;feel&#8217; how they would work (or not). After experiencing this I decided to do some substantial changes to the UI. Dragging and dropping is all nice and dandy, but it&#8217;s too much clicking and dragging for the app. On paper this really looked cool but in practice it was not. </p>
<p>It&#8217;s amazing what you can do with jQuery. You can save state on elements using Html 5 attribute, can load other Html snippets as Ajax responses and use a dozen jQuery plugins for menus, zooming, dragging and so on. Not to mention the power of jQuery itself. You can append action, animations or anything to any element. Without programming one line server side I got a fully working prototype running including adding and removing items, saving, loading and dynamic generated forms.</p>
<p>Some more iterations later (still not 100% happy) I started to implement it for real. Since I wanted to stay with that design (and very much Ajax oriented) I went the route of <a href="http://directwebremoting.org/dwr/index.html">Direct Web Remoting</a> and <a href="http://freemarker.sourceforge.net/">Freemarker</a>. Freemarker will render my templates and DWR talks to my Spring beans. Whenever I needed to design another page I first did the standalone Html version, got it to a working state and then integrated it in the app.</p>
<h3>Conclusion</h3>
<p>Even if I would not have decided to use jQuery and pure Html for the final implementation (totally depends on the use case) I would strongly consider going the same route for doing the prototype again. It was so easy and the feedback was right there. I could throw away not working ideas  and make new ones very easily. There was a learning curve using jQuery (and I needed to refresh my CSS) but it was time well invested.</p>
<p>How do you your prototypes? Fully integrated with your existing frameworks or on paper? </p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=532&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer&amp;url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;bm_description=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/&amp;title=Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Lightweight+Web+Prototyping+for+the+Framework+loving+%28Java%29+Developer+@+http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/P1JG91zYXuI" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/04/20/lightweight-web-prototyping-for-the-framework-loving-java-developer/</feedburner:origLink></item>
		<item>
		<title>How we switched from Subversion to Git</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/FpWDURbfabw/</link>
		<comments>http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/#comments</comments>
		<pubDate>Mon, 22 Mar 2010 13:00:11 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[git subversion]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=497</guid>
		<description><![CDATA[
			
				
			
		

So I heard about these strange distributed version control systems like over a year ago. I used it in my own little projects and everything went smoothly and I really liked it.
The idea also caught on at work and my team started a using Git in a fresh project last summer. We did not had [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F03%2F22%2Fhow-we-switched-from-subversion-to-git%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F03%2F22%2Fhow-we-switched-from-subversion-to-git%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><img class="alignleft" src="http://git.wiki.kernel.org/images-git/2/24/Gitlogo.svg_from_msysGit.png" title="© GitLogo @ mssysgit"  /><br />
So I heard about these strange <strong>distributed version control system</strong>s like over a year ago. I used it in my own little projects and everything went smoothly and I really liked it.<br />
The idea also caught on at work and my team started a using Git in a fresh project last summer. We did not had so much problems since you can use Git very much like a central vcs like Subversion if you want to.</p>
<p>Still, for all other code, we <strong>used Subversion</strong>.<br />
We believe in agile and feature branches, so that&#8217;s what we do a lot. Every story has its own branch. If one story touches multiple code bases, that means multiple <a href="http://www.infoq.com/articles/agile-version-control">merge down/copy up&#8217;s</a>.<br />
At some point, in preparation for a sprint review, we found that code had disappeared from the trunk. Everything seems to work perfectly, just this feature was missing. Usually you would think if code was deleted, there would be at least one test failing and telling you that something is missing. But no, typing <strong>one wrong version number</strong> during merge down/copy up <strong>cut out the story</strong> very cleanly. Once we found the problem we could merged it back in from the not yet deleted feature branch.<br />
Overall we managed to work with Subversion but it was a growing pain since we knew there was something better. </p>
<p>There are several advantages of distributed version control system which you all might have heard of already so I won&#8217;t go in to detail of this (of course there is also one major disadvantage: complexity). The <strong>main advantages</strong> for me are:</p>
<ul>
<li>Everything is local &#8211; very fast</li>
<li>Merging is much much easier (or updating from another repo)</li>
<li>Because merging is easier I tend to branch more often to try out ideas</li>
</ul>
<p>Now, what does it take for my team to get Git going in all major code bases?</p>
<h1>Technology</h1>
<p>Here is our setup what we use at work:</p>
<ul>
<li>Windows PC, some Mac OS X</li>
<li>IntelliJ Idea 9.0.x</li>
<li>Teamcity 5.0.x</li>
<li>Maven</li>
</ul>
<h3>The OS: Windows and Mac</h3>
<p>Basically no surprise here. <strong>Works</strong> on both machines.</p>
<h3>The IDE: IntelliJ Idea 9</h3>
<p>Idea does support Git. I do like the approach which they took to simply use the git binary of your operating system. With the version control console you can see what Idea is doing. This way you can watch and learn. Back with subversion we had sometimes trouble using two different tools for handling subversion problems, like Idea and Tortoise SVN. Using the same tool for everything will make it easier.<br />
The Git integration is not perfect but it <strong>does work well</strong>.</p>
<h3>Continuous Integration: Teamcity</h3>
<p>Teamcity does support Git the same way as Subversion. There is one drawback however: <strong>Pre-Tested checkins are not supported yet</strong>. This cool features allows you to run all tests before checking in. You will never have a broken branch/trunk if you use it! Basically it will take your changes to the code base, runs all tests and only commits them if everything passes. Sadly, it does not work with Git (yet, but you can <a href="http://youtrack.jetbrains.net/issue/TW-11344">vote for this feature</a>).<br />
Teamcity does allow you however to do a remote run with the changes you committed locally. So you check in everything locally and while Teamcity runs all the tests you can keep on coding. Running all tests with your current changes in the change list is also supported.<br />
Teamcity uses JGit and has some limitations (like no tagging support). In Teamcity 5.1 they want to use the Git binary as well.</p>
<p>Another problem, which I will talk about in the next section, is agent side checkout.</p>
<h3>Build Tool: Maven</h3>
<p><strong>Maven supports git as scm</strong>. Nothing more to say. </p>
<p>Since we are releasing our software every other week we automated the build process to two stages. Building the release and packaging different build artifacts. We used to have a button in Teamcity, push it and 30 minutes later we had a release. Unfortunately the way Teamcity supports Git is that the code which will get checkout does not have a .git directory (and for maven it is not under source control). I still wonder what the heck they are doing there. Without that, maven can not advance the version numbers in your pom and you are stuck. Please go and <a href="http://youtrack.jetbrains.net/issue/TW-10741">vote for this feature now</a>. Thanks.<br />
Until then we just do it like in the good old times and do a maven release from the command line.</p>
<h1>People</h1>
<p>While everything so far was technical, the biggest challenge might be mindset of the people and support from your friendly manager. </p>
<p>I&#8217;m lucky that my boss is very hands on and really liked that idea (also, since he was the one we usually asked if we yet again had problems with Subversion properties being messed up somehow). Otherwise you might need to do some ROI calculation why this really is a good idea.</p>
<p>What I encourage is that <strong>every team needs to have 1 or 2 people interested in git</strong>. The others in the team should see the benefit of it, even though they don&#8217;t know how git works. My advice would be that one person would give a  <strong>20 minutes presentation of what you can do</strong> with it to all interested co workers. We did not do it,  but looking back, we should have done it. Make sure that you bring across the message that switching scm&#8217;s will not be that easy. If possible make everyone <strong>read the first 3 chapters</strong> of the freely available <strong><a href="http://progit.org/book">Pro Git</a></strong> book (and also  buy a copy or two for the library). This will give them a much better understanding.<br />
It is change and <strong>change usually causes some trouble</strong>. We got a <strong>team commitment</strong> for it so at least nobody was opposed to it. If a couple of people are not happy with the way how the new things are around here, they will have an easy time to make a loud and clear statement that switching to Git was a bad idea. Git is more complex but also more powerful. </p>
<p>I did a  <strong>plan</strong> on how to <strong>migrate</strong>. This took me just a couple of hours. </p>
<ul>
<li>Which code bases to migrate</li>
<li>Where to put the git repositories? Use the filesystem, SSH, <a href="http://gitorious.org/">Gitorius</a>, <a href="http://eagain.net/gitweb/?p=gitosis.git">Gitosis</a>, <a href="http://fi.github.com/">Github:fi</a> </li>
<li>You might need more infrastructure, everybody needs ssh keys</li>
<li>Any depended processes</li>
<li>External collaborators</li>
<li>When does operations have time to implement it</li>
<li>Does the release process still work</li>
<li>Continuous Integration System</li>
<li>Test conversion of the subversion repository</li>
<li>Access rights</li>
<li>&#8230; there might be more I forgot about</li>
</ul>
<p>Plan and test these as much as you can. We started to use git just to discover that we missed some use cases like our automated runs to check the external web service dependencies. Two people doing the planning certainly helps.</p>
<p>After start using it, we had  <strong>one guy</strong> (me) who went around for the first 2-3 days and <strong>helped people with their git related problems</strong>. There will be problems, I promise!</p>
<p>We did migrate all of our code at once since we did not want to be stuck between two vcs&#8217;s. We will go with Gitorius and ssh based authentication. Since we do not have a server for that (yet) we use a shared drive for the time being as a repository. Being distributed it will be no problem for Git to change it&#8217;s location later on.</p>
<p>The first two of days were a bit tricky but it got much smoother after we all got used to it. </p>
<p>The<strong> work flow is different</strong> and it will take some time until everybody takes advantages of all the features like commit your files more often or make more private branches to try out ideas.<br />
We <strong>started with a similar work flow</strong> we are used to  and plan to introduce one feature of git at a time. This could have been better. <strong>Iron out the known commit habits with Git</strong> and make sure this works in your favorite IDE before hand. It is very important to make the transition a better experience. </p>
<p>We started just this month but we already had some nice effects like merging two branches with renamed files. On guy changed file and somebody else renamed the same file in his repository.  As he merged in the changes, the change appeared in the renamed file. Really great. </p>
<p>Do you use a distributed version control system? How did your transition go ?</p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=497&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=How+we+switched+from+Subversion+to+Git&amp;url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;bm_description=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/&amp;title=How+we+switched+from+Subversion+to+Git" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+How+we+switched+from+Subversion+to+Git+@+http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/FpWDURbfabw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/03/22/how-we-switched-from-subversion-to-git/</feedburner:origLink></item>
		<item>
		<title>5 code metrics you need to watch</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/l3WUXz8OX04/</link>
		<comments>http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/#comments</comments>
		<pubDate>Tue, 23 Feb 2010 14:00:27 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Agile]]></category>
		<category><![CDATA[complexity]]></category>
		<category><![CDATA[coverage]]></category>
		<category><![CDATA[metric]]></category>
		<category><![CDATA[quality]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=459</guid>
		<description><![CDATA[
			
				
			
		

Developing software ain&#8217;t easy.
How do you know how you are doing ?
You could start collecting metrics about your code. These can give you some indication how maintainable and  reliable  it is.
The metric which come to mind to the most people is code coverage. Some people say it must be near 100%, other say 80% is [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F02%2F23%2F5-code-metrics-you-need-to-watch%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F02%2F23%2F5-code-metrics-you-need-to-watch%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><a href="http://www.flickr.com/photos/iliahi/2606644514/sizes/s/" title="© Biking Nikon PDX@flickr" ><img class="alignleft" src="http://farm4.static.flickr.com/3241/2606644514_b6f294fb2e_m.jpg" title="© Biking Nikon PDX@flickr" width="240" height="167" /></a></p>
<p>Developing software ain&#8217;t easy.</p>
<p>How do you know how you are doing ?</p>
<p>You could start <strong>collecting metrics</strong> about your code. These can give you some indication how maintainable and  reliable  it is.</p>
<p>The metric which come to mind to the most people is <strong>code coverage</strong>. Some people say it must be near 100%, other say 80% is a good number. At the end it can&#8217;t tell you if you are doing great or good. The only thing you might read from it is that a <strong>low number</strong> indicates a <strong>potential problem</strong>.</p>
<p>Duplication is another one you should look out for. A high number of <strong>duplicated code</strong> might bring up the problem that a bug was fixed in one place but lives on in other. If you are doing code generation (e.g. from WSDL&#8217;s) you might have a lot of duplicated code reported to you. A closer inspection is needed to really make sure this is a problem in the code you have written and is not auto generated.</p>
<p><strong>Test success</strong> is not a metric you should be worried to much about. It just needs to be <strong>100% </strong>at every checking in a shared repository. <strong>No discussion</strong>.</p>
<p><a href="http://en.wikipedia.org/wiki/Cyclomatic_complexity"><strong>Cyclomatic complexity</strong></a> let&#8217;s you measure the number of linearly independent paths through your code. A high number means a more complex code. A complex code base is hard to maintain and involves a lot of work to adopt it to new requirements.</p>
<p>Dependencies between packages is another important value to check on (see <a href="http://www.objectmentor.com/resources/articles/granularity.pdf">Uncle Bob&#8217;s paper on Acyclic Dependency Principle</a>). Basically it revolves around that packages should not have <strong>cyclic dependencies</strong> between them since this does have an impact on releasing and testing (and therefore coding).  A change in one package could trigger a whole system build to make sure everything works together.</p>
<p>Tools like Findbugs let you define rules to which your code should comply to. This is great because it is tailored to your code/company and ensures you control and fine tune the measures. Or so. It requires some time to define these rules. They need to be refined over time and you have to understand them to make use of it. Of course you can leave out some of these and reduce complexity. Do not underestimate the effort to implement these.</p>
<p>This rounds up the metrics you can get from your code base.</p>
<p>But wait, there is <strong>more</strong>.</p>
<p>A valuable metric is the <strong>meantime between reporting</strong> a feature or bug <strong>and fixing</strong>. This gives your team (and management of course) a rough estimate how fast you can react to market changes.</p>
<p>To get an estimate of the mean time before a failure happens you can <strong>measure the time between two bugs</strong>. The higher the number the better. Current reported bugs per lines of code can also be measured. These metrics will give you some confidence in your code base.</p>
<p>At the end of the day the <strong>ultimate measure</strong> is the money on the company&#8217;s bank account. If this is not working out you are in trouble.</p>
<h2>How to get all of these ?</h2>
<p>There are some static code analysis tools to get you started. I only can talk about Java related tools but there <a href="http://en.wikipedia.org/wiki/List_of_tools_for_static_code_analysis">are others</a> as well.</p>
<ul>
<li><a href="http://checkstyle.sourceforge.net/">Checkstyle</a></li>
<li><a href="http://findbugs.sourceforge.net/">FindBugs</a></li>
<li><a href="http://pmd.sourceforge.net/">PMD</a></li>
<li><a href="http://cobertura.sourceforge.net/">Cobertura</a></li>
<li><a href="http://www.headwaysoftware.com/products/structure101/index.php">Structure 101</a></li>
<li><a href="http://sonar.codehaus.org/">Sonar</a></li>
</ul>
<p>To get more information about your bugs should query your bug tracking system like <a href="http://www.atlassian.com/software/jira/">Jira</a> or <a href="http://www.bugzilla.org/">Bugzilla</a>.</p>
<h2>Summary</h2>
<p>There are much more numbers out there but I think these are the ones you should always keep an eye on.</p>
<p>Look out for</p>
<ul>
<li>Code Coverage</li>
<li>Duplication</li>
<li>Cyclomatic complexity</li>
<li>Cyclic dependencies</li>
<li>Test success</li>
<li>Time to market</li>
<li>Mean time between failure</li>
</ul>
<p>What metrics do you look out for ? <strong>Let me know </strong> in in the comments and why.</p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=459&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=5+code+metrics+you+need+to+watch&amp;url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;bm_description=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/&amp;title=5+code+metrics+you+need+to+watch" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+5+code+metrics+you+need+to+watch+@+http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/l3WUXz8OX04" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/02/23/5-code-metrics-you-need-to-watch/</feedburner:origLink></item>
		<item>
		<title>Name your objects right</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/beABP1DZf9I/</link>
		<comments>http://maxheapsize.com/2010/02/09/name-your-objects-right/#comments</comments>
		<pubDate>Tue, 09 Feb 2010 15:00:21 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[naming]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=447</guid>
		<description><![CDATA[
			
				
			
		
Whenever you create an object you have to find a meaningful name.
While renaming later in modern IDE&#8217;s is no problem at all you should not pick the first name which comes to your mind. 
Imagine you have an external fraud detection web service and it will return a &#8216;hit&#8217; or &#8216;miss&#8217;. How do you name [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F02%2F09%2Fname-your-objects-right%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F02%2F09%2Fname-your-objects-right%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p><a href="http://www.flickr.com/photos/nataliemaynor/2988366432/sizes/s/"><img alt="No Name" src="http://farm4.static.flickr.com/3220/2988366432_8f39394055_m.jpg" title="&copy; NatalieMaynor @ flickr" width="180" height="240" /></a><br />
Whenever you create an object you have to find a meaningful name.</p>
<p>While renaming later in modern IDE&#8217;s is no problem at all you should not pick the first name which comes to your mind. </p>
<p>Imagine you have an external fraud detection web service and it will return a &#8216;hit&#8217; or &#8216;miss&#8217;. How do you name this object? HitOrMiss maybe (since this is the representation you get from the webservice) ? It might describe the problem at hand. If you go with this name it will dripple down through all layers. The domain model, the dto&#8217;s, services and more will now reference to this object (and create their own derivates for it). Your colleagues which code up other parts of the system will refer to it and create their own variants of the name (like structure for web pages). The wrong name is now all over your code.</p>
<p>So much for refactoring in your IDE. You will never catch all the places automatically where the wrong name was used.</p>
<p>While it <strong>seemed lost time</strong> discussing the &#8216;right&#8217; name for 5 minutes in the beginning it <strong>saves</strong> you much more <strong>time</strong> afterwards. Of course you might get also confused a couple of weeks later remembering what this thing really does and what it is used for.</p>
<p>Make sure you take time in naming your objects. A <strong>wrong decision</strong> can do some <strong>harm</strong> to your code. The later it turns out that the name was not correct the much more <strong>expensive</strong> it becomes <strong>to correct</strong> this mistake. If you are not really sure how to name it, talk to your colleagues and discuss the name. A second opinion can not hurt.	</p>
<p>Maybe FraudDetectionResult would have been a better choice. </p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=447&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Name+your+objects+right&amp;url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/02/09/name-your-objects-right/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;bm_description=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/02/09/name-your-objects-right/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/02/09/name-your-objects-right/&amp;title=Name+your+objects+right" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/02/09/name-your-objects-right/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Name+your+objects+right+@+http://maxheapsize.com/2010/02/09/name-your-objects-right/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/beABP1DZf9I" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/02/09/name-your-objects-right/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/02/09/name-your-objects-right/</feedburner:origLink></item>
		<item>
		<title>One year of blogging</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/34QNLIUXd24/</link>
		<comments>http://maxheapsize.com/2010/02/06/one-year-of-blogging/#comments</comments>
		<pubDate>Sat, 06 Feb 2010 19:46:59 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Blog]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=441</guid>
		<description><![CDATA[
			
				
			
		
One year ago I started to blog again. Time for a little recap.
Why did I do it ?
I use this blog to write down my own thoughts about software and development. This is for my own reference but also it is a little way to give something back to the world wide community in return [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F02%2F06%2Fone-year-of-blogging%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F02%2F06%2Fone-year-of-blogging%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<div class="wp-caption alignnone" style="width: 181px"><a href="http://www.flickr.com/photos/mrs_logic/3799729875/sizes/s/"><img alt="&copy; Mrs Logic @ flickr" src="http://farm3.static.flickr.com/2509/3799729875_16098fe242_m.jpg" title="One Year" width="171" height="240" /></a><p class="wp-caption-text">&copy; Mrs Logic @ flickr</p></div>
<p>One year ago I started to blog again. Time for a little recap.</p>
<p><strong>Why did I do it ?</strong></p>
<p>I use this blog to write down my own thoughts about software and development. This is for my own reference but also it is a little way to give something back to the world wide community in return for all the useful stuff I do read on the net.</p>
<p>I noticed how this also made me a <a href="http://www.joergm.com/2010/01/why-all-programmers-should-blog/">better programmer</a>. Try it out by yourself. Having a professional blog is also a good way for <a href="http://www.chrisbrogan.com/develop-a-strong-personal-brand-online-1/">Personal branding</a>.</p>
<p><strong>Stats for the last 12 months</strong></p>
<p>I love number so here they are:</p>
<p>About 15.000 unique visitors<br />
About 20.000 pageviews</p>
<p><em>Traffic</em></p>
<p>20.64 % Direct Traffic<br />
36.34 % Referring Sites<br />
42.44 % Search Engines</p>
<p>Highest page views on one day: the <a href="http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/">Selenium 2</a> post, 620 pageviews (ok, this was big link of the day at dzone.com).</p>
<p><em>Countries</em></p>
<p>I had visitors from 120 countries.</p>
<p>3362 visitors from United States<br />
2090 visitors from Germany<br />
776 visitors from United Kingdom </p>
<p><em>Top posts</em></p>
<p><a href="http://maxheapsize.com/2009/04/11/getting-the-browsers-geolocation-with-html-5/">GeoLocation with HTML5</a> 2670 pageviews<br />
<a href="http://maxheapsize.com/2009/07/03/getting-started-with-jsf-2-and-maven/">JSF 2 and maven</a> 2607 pageviews<br />
<a href="http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/">Selenium 2</a> and <a href="http://maxheapsize.com/2009/10/13/concordion-vs-cucumber-and-java-based-acceptance-testing/">Concordion vs. Cucumber</a> each 1566 pageviews</p>
<p>I have 142 RSS subscribed readers.</p>
<p>All in all, not too shaby <img src='http://maxheapsize.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> .</p>
<p><strong>Thanks</strong></p>
<p>Thanks to everybody for reading my thoughts. Thanks for the comments and hints.  </p>
<p>I&#8217;m looking forward to the next year. It is going to be a great one.</p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=441&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=One+year+of+blogging&amp;url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/02/06/one-year-of-blogging/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;bm_description=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/02/06/one-year-of-blogging/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/02/06/one-year-of-blogging/&amp;title=One+year+of+blogging" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/02/06/one-year-of-blogging/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+One+year+of+blogging+@+http://maxheapsize.com/2010/02/06/one-year-of-blogging/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/34QNLIUXd24" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/02/06/one-year-of-blogging/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/02/06/one-year-of-blogging/</feedburner:origLink></item>
		<item>
		<title>What’s your preferred development infrastructure stack?</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/SOFoWrjVmXQ/</link>
		<comments>http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/#comments</comments>
		<pubDate>Wed, 13 Jan 2010 14:25:42 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[infrastructure]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=435</guid>
		<description><![CDATA[
			
				
			
		
In Response to Matt Raible&#8217;s question about my preferred development stack.
Source control
In my own development project I switched to Git some time ago. I was using svn and before that cvs for a couple of years. Git just makes it easy to try out small ideas very quickly without reverting the code. We will introduce [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F01%2F13%2Fwhats-your-preferred-development-infrastructure-stack%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F01%2F13%2Fwhats-your-preferred-development-infrastructure-stack%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<p>In Response to <a href="http://raibledesigns.com/rd/entry/what_s_your_preferred_development">Matt Raible&#8217;s</a> question about my preferred development stack.</p>
<h3>Source control</h3>
<p>In my own development project I switched to <a href="http://git-scm.com">Git</a> some time ago. I was using svn and before that cvs for a couple of years. Git just makes it easy to try out small ideas very quickly without reverting the code. We will introduce Git at work pretty soon (I hope).</p>
<h3>The Atlassian cloud</h3>
<p>I was using <a href="http://www.atlassian.com/software/confluence/">Confluence</a> as a Wiki in my open source project and my current employer <a href="http://www.hypoport.de">Hypoport</a> uses it as well.  Bug tracking is pretty much a task of <a href="http://www.atlassian.com/software/jira/">Jira</a>. Those two integrate very nicely. You can have ping backs in your Jira Ticket from Confluence, so you see all related files. I would love to use <a href="http://www.atlassian.com/software/fisheye/">FishEye</a> but I&#8217;m not sure how to justify the costs and what the added value is in our case.</p>
<h3>The Code</h3>
<p>I&#8217;m pretty much sold to <a href="http://www.jetbrains.com/idea/index.html">Jetbrains IntelliJ Idea</a>. I&#8217;m using it for 5 years now. With it comes <a href="http://www.jetbrains.com/teamcity/">Teamcity</a>. It&#8217;s a very nice continuous integration tool where the biggest plus (among other things) is the delayed (and pre tested) checkin. No more late night checkins which break the master. We just rolled out the latest version which has a much nicer Git integration (so we can make the switch).</p>
<p>So it comes down to:</p>
<h3>The List</h3>
<ul>
<li>Source control: <b>Git</b></li>
<li>Wiki: <b>Atlassian Confluence</b></li>
<li>Continuous Integration: <b>Jetbrains Teamcity</b></li>
<li>Bugtracker: <b>Atlassian Jira</b></li>
</ul>
<p>We are about to use <a href="http://sonar.codehaus.org/">Sonar</a> for code analysis and development over time, but this is just in the beginning.</p>
<p>What&#8217;s yours ?</p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=435&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F&amp;url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;bm_description=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/&amp;title=What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+What%26%238217%3Bs+your+preferred+development+infrastructure+stack%3F+@+http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/SOFoWrjVmXQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/01/13/whats-your-preferred-development-infrastructure-stack/</feedburner:origLink></item>
		<item>
		<title>Using Selenium2 for web testing (and not Selenium IDE)</title>
		<link>http://feedproxy.google.com/~r/maxheapsizecom/~3/op67gXhBwXA/</link>
		<comments>http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 05:38:15 +0000</pubDate>
		<dc:creator>Oliver Wehrens</dc:creator>
				<category><![CDATA[Web]]></category>
		<category><![CDATA[selenium]]></category>
		<category><![CDATA[selenium ide]]></category>
		<category><![CDATA[selenium2]]></category>
		<category><![CDATA[test]]></category>
		<category><![CDATA[webdriver]]></category>

		<guid isPermaLink="false">http://maxheapsize.com/?p=393</guid>
		<description><![CDATA[
			
				
			
		
Selenium IDE
Selenium is well know for automatic testing web pages. It does support many browsers, operating systems and languages. A Selenium IDE exists to aid you creating automated tests. 
It is possible to write extensions in JavaScript to have data driven tests. If you organize your selenium tests in a way that you split  [...]]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F01%2F04%2Fusing-selenium-2-for-web-testing%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fmaxheapsize.com%2F2010%2F01%2F04%2Fusing-selenium-2-for-web-testing%2F&amp;source=owehrens&amp;style=normal" height="61" width="50" /><br />
			</a>
		</div>
<h3>Selenium IDE</h3>
<p><a href="http://seleniumhq.org">Selenium</a> is well know for automatic testing web pages. It does support many <a href="http://seleniumhq.org/about/platforms.htm">browsers, operating systems and languages<a/>. A <a href="http://seleniumhq.org/projects/ide/">Selenium IDE</a> exists to aid you creating automated tests. </p>
<div class="wp-caption alignleft" style="width: 313px"><img alt="Selenium" src="http://maxheapsize.com/static/selenium.png" title="Selenium IDE" width="303" height="177" /><p class="wp-caption-text">Selenium IDE</p></div>
<p>It is possible to write extensions in JavaScript to have data driven tests. If you organize your selenium tests in a way that you split  the pages and forms in components, you can  load up new data for the tests (written in xml) to fill out forms differently for each use case. The Selenium IDE will be of a great help here since you start develop the tests in the IDE and later &#8216;just&#8217; parametrize the pages. With a couple of more javascript magic you can run these as well in <a href="http://seleniumhq.org/projects/remote-control/">Selenium Remote Control</a> (Selenium RC for short). This even works for running  the tests in continuous integration systems like Hudson or Teamcity.</p>
<p>Great Stuff.</p>
<h3>The problem.</h3>
<p>The drawback coding up your tests with the Selenium IDE is: <b>HTML</b>.  </p>
<p>You will end up with some test suites including many test scenarios. It will be one big ball of </p>
<pre class="brush: xml;">
&lt;tr&gt;
  &lt;td&gt;type&lt;/td&gt;
  &lt;td&gt;accountnumber:Value&lt;/td&gt;
  &lt;td&gt;82892892811&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td&gt;type&lt;/td&gt;
  &lt;td&gt;accountAmount:Value&lt;/td&gt;
  &lt;td&gt;2345.33&lt;/td&gt;
&lt;/tr&gt;
</pre>
<p>You will build components and you will end up with GotoIf and Label statements. Back to Basic programming from the 80ties. Without more javascript extensions you also can&#8217;t reuse combinations of scenarios. </p>
<p>While this works pretty ok: I&#8217;m a programmer and do have a <strong>problem</strong> with the <strong>quality of the produced code</strong>. It&#8217;s <strong>easy to mess up</strong>. It&#8217;s <strong>not safe for refactoring</strong>. To extend functionality you need to have javascript knowledge. Depending on your company profile (e.g. java shop) , this might be a problem.  Having a dedicated tester on the team certainly helps to overcome these obstacles, but if everybody in the team just once in a while looks into the Selenium IDE tests, the quality and the reliability of the code will not improve. Not to mention all the <strong>copy and paste</strong>. Been there, done that.</p>
<h3>Selenium 2</h3>
<p>A much nicer approach for me would be something like this:</p>
<pre class="brush: java;">
WebDriver driver  = new FirefoxDriver();
AppWebTest test = new AppWebTest(driver, &quot;http://myapp.com/login&quot;);
LoggedInUser user = test.login(&quot;user&quot;, &quot;password&quot;);
Account account = user.createNewAccount(&quot;DemoAccount&quot;);
account.addPerson(PersonFactory.createPersonWithNoIncome());
...
account.verify();
</pre>
<p>This would log in a user, creates an account and assigns a person to it. Everybody could <strong>read and understand</strong> it. Furthermore you can easily reuse components and logic. I would imagine that creating a DSL, matchers and finders is everything one would need to have a very nice test scenario.</p>
<p>All that is already possible with Selenium 1 and the language bindings (more or less). </p>
<p>Just with the release of the first alpha of Selenium 2 mid december 2009 it became just a little bit easier.</p>
<p>Selenium 2 is the <strong>combined effort</strong> of Google&#8217;s Webdriver and Selenium. Webdriver tries to <a href="http://google-opensource.blogspot.com/2009/05/introducing-webdriver.html">tackle</a> Seleniums problems with Javascript and the security model as well as the complex Selenium RC API. </p>
<blockquote><p>
Selenium is written in JavaScript which causes a significant weakness: browsers impose a pretty strict security model on any JavaScript that they execute in order to protect a user from malicious scripts.<br />
&#8230;<br />
Additionally, being a mature product, the API for Selenium RC has grown over time, and as it has done so it has become harder to understand how best to use it. For example, it&#8217;s not immediately obvious whether you should be using &#8220;type&#8221; instead of &#8220;typeKeys&#8221; to enter text into a form control. Although it&#8217;s a question of aesthetics, some find the large API intimidating and difficult to navigate.
</p></blockquote>
<p>Webdriver does not use JavaScript to control the web browser but <strong>uses native controls</strong>, e.g. an extension for Firefox or the native automation extensions of IE. Furthermore it introduces an object based API instead of following Seleniums directory based approach.</p>
<p>So given the above example the login method would look something like this:</p>
<pre class="brush: java;">
 public LoggedInUser login(String userName, String password) {
    driver.get(url);
    driver.findElement(By.id(&quot;user&quot;)).sendKeys(userName);
    driver.findElement(By.id(&quot;password&quot;)).sendKeys(password);
    driver.findElement(By.id(&quot;login&quot;)).click();

    LoggedInUser user = new LoggedInUser(driver);

    WebElement startPage = driver.findElement(By.id(&quot;startPage&quot;));

    assertThat(startPage().getText()).isEqualTo(&quot;Start&quot;);
    return user;
  }
</pre>
<p>You can take this to any level. It took me just a few hours to model the above use case with componentized input elements. </p>
<p>With a bit more abstraction addPerson looks something like the following code. Whatever is needed to add a person to an account will be replayed. This is what Selenium IDE would normally do.</p>
<pre class="brush: java;">
public void addPerson(Person person) {
    jumpToAccountOverView();
    clickOnLink(&quot;menu:Overview&quot;);
    clickOnLink(&quot;table_personTable:link_newPerson&quot;);

    inputGuiElement(person.getTitle());
    inputGuiElement(person.getLastName());
...
    clickSave();
</pre>
<p>And now for the best part. You <strong>don&#8217;t really need a real web browser</strong>. Selenium 2 supports 4 WebDriver: </p>
<ul>
<li>Firefox</li>
<li>Chrome</li>
<li>Internet Explorer (on Windows)</li>
<li>HtmlUnit</li>
</ul>
<h3>HtmlUnit</h3>
<p>With enabled JavaScript on HtmlUnit (it uses Rhino, so not all JavaScript tricks might work, could be a drawback depending on your scenario) I can run my test as <strong>TestNG or JUnit</strong> test case. No need for a Selenium RC anymore. <strong>No  browsers running locally</strong> or on remote machine listing to ports to execute tests and transmitting results back. </p>
<p>It is very useful to have the Selenium RC take screen shots during it&#8217;s run. Selenium 2 can&#8217;t do this right now (and with HtmlUnit never can). But by simply integrating some logging in the components and elements and you know right away where things went wrong.<br />
Developing with the <strong>Selenium IDE</strong> might seem like a must, but during the work on my prototype all I needed was Firebug and a XPath Searcher. I <strong>did not miss it</strong> at all. To do integration tests you could test all components independently and one at a time. Once these work, chain them together and let them run as unit tests. Did I mention <strong>HtmlUnit is fast</strong> ? </p>
<h3>Conclusion</h3>
<p>I barely dug into the webdriver code, I played around with it for a couple of hours and I&#8217;m sure there more is stuff (and bugs) to find. Given that Selenium 2 is in alpha 1 stage right now I expect very nice things coming out of it. It certainly looks like the way to go. </p>
<p>Another strong contender is <a href="http://webtest.canoo.com/webtest/manual/WebTestHome.html">Canoo WebTest</a>. I will have a look at this one in another post.</p>
<p><strong>Update Ajax and HtmlUnit</strong> 1/5/2010 </p>
<p>It does not seem to work. You need a real browser to get dynamically content re-rendered through Ajax. </p>
<p>A method waiting for an id to be rendered (or timeout after x seconds) could look like this:</p>
<pre class="brush: java;">
  public void waitForElementOrTimeout(String idToWaitFor, int timeout) {
    long end = System.currentTimeMillis() + timeout * 1000;
    RenderedWebElement resultsDiv = null;
    while (System.currentTimeMillis() &lt; end) {
      try {
        resultsDiv = (RenderedWebElement) driver.findElement(By.id(idToWaitFor));
      }
      catch (NoSuchElementException e) {
        //
      }
      if (resultsDiv != null &amp;&amp; resultsDiv.isDisplayed()) {
        break;
      }
    }
    assertThat(resultsDiv).isNotNull();
  }
</pre>
<p>This will either find the element specified or throw an assertion (updated example from the selenium 2 page).</p>
<img src="http://maxheapsize.com/?ak_action=api_record_view&id=393&type=feed" alt="" /><!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.dzone.com/links/add.html?description=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29&amp;url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;DZone"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/dzone.png" title="Add to&nbsp;DZone" alt="Add to&nbsp;DZone" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.mister-wong.com/index.php?action=addurl&amp;bm_url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;bm_description=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;Mister Wong"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/misterwong.png" title="Add to&nbsp;Mister Wong" alt="Add to&nbsp;Mister Wong" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.sphere.com/sphereit/http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/" rel="nofollow" title="Add to&nbsp;SphereIt"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/sphereit.png" title="Add to&nbsp;SphereIt" alt="Add to&nbsp;SphereIt" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.spurl.net/spurl.php?url=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/&amp;title=Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29" rel="nofollow" title="Add to&nbsp;Spurl"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/spurl.png" title="Add to&nbsp;Spurl" alt="Add to&nbsp;Spurl" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Using+Selenium2+for+web+testing+%28and+not+Selenium+IDE%29+@+http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://maxheapsize.com/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
<img src="http://feeds.feedburner.com/~r/maxheapsizecom/~4/op67gXhBwXA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		<feedburner:origLink>http://maxheapsize.com/2010/01/04/using-selenium-2-for-web-testing/</feedburner:origLink></item>
	</channel>
</rss>
