<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Colin Howe's Blog</title>
	<atom:link href="http://colinhowe.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://colinhowe.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Fri, 09 Dec 2011 23:25:19 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='colinhowe.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Colin Howe's Blog</title>
		<link>http://colinhowe.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://colinhowe.wordpress.com/osd.xml" title="Colin Howe&#039;s Blog" />
	<atom:link rel='hub' href='http://colinhowe.wordpress.com/?pushpress=hub'/>
		<item>
		<title>RK4 in Scala</title>
		<link>http://colinhowe.wordpress.com/2009/08/27/rk4-in-scala/</link>
		<comments>http://colinhowe.wordpress.com/2009/08/27/rk4-in-scala/#comments</comments>
		<pubDate>Thu, 27 Aug 2009 19:22:36 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[scala]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=86</guid>
		<description><![CDATA[I&#8217;ve been looking at Scala recently and I&#8217;m impressed. It&#8217;s got a nice mix of imperative and functional styles that means that it can be really useful and easy to code in. As an example I thought I&#8217;d knock up an implementation of RK4 in it. The work-horse of RK4 is implemented as follows: def [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=86&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been looking at Scala recently and I&#8217;m impressed. It&#8217;s got a nice mix of imperative and functional styles that means that it can be really useful and easy to code in.</p>
<p>As an example I thought I&#8217;d knock up an implementation of <a href="http://en.wikipedia.org/wiki/Runge%E2%80%93Kutta_methods">RK4</a> in it.</p>
<p>The work-horse of RK4 is implemented as follows:</p>
<pre style="font-size:14px;">
def rk4Iter(f: (Double, Double) =&gt; Double,
            t : Double,
            y : Double,
            h : Double) = {
  val k1 = f(t, y)
  val k2 = f(t + h / 2, y + h * k1 / 2)
  val k3 = f(t + h / 2, y + h * k2 / 2)
  val k4 = f(t + h, y + h * k3)
  y + h * (k1 + k2 * 2 + k3 * 2 + k4) / 6
}
</pre>
<p>One thing I think we can all agree on is that having functions as first-class objects makes this incredibly succinct and easy to follow. I&#8217;m just calling the function <i>f</i> a whole bunch of times. Coming from a Java background this is pleasantly less noisy (compare with f.calculate(t, y) etc).</p>
<p>Another subtlety is the lack of specifying a return type. Scala is smart enough to infer the return type <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>This method is intended to be called from a loop that performs <i>n</i> steps of size <i>h</i>:</p>
<pre style="font-size:14px;">
def rk4(f: (Double, Double) =&gt; Double,
            t0 : Double,
            y0 : Double,
            n : Int,
            h : Double)
    : Double = {
  n match {
    case 0 =&gt; y0
    case _ =&gt;
      val y1 = rk4Iter(f, t0, y0, h)
      rk4(f, t0 + h, y1, n - 1, h)
  }
}
</pre>
<p>For those coming from a Java background you&#8217;ll notice that match looks a lot like switch. You can think of it as switch on steroids (I&#8217;ll leave off explaining more as it&#8217;s a blog post in its own right!). It is sufficient to say that case _ is similar to default.</p>
<p>In functional programming the preferred way to do things is using recursion rather than iteration (when written properly the compiler can identify tail-recursive functions and make them just as fast as loops). We do this because it makes them easier to mathematically reason about them. Suppose the function works for:</p>
<ul>
<li>the 0th case</li>
<li>the <i>n</i>th case if it works for the <i>n -1</i>th case
</ul>
<p>then the function works for all positive integers.</p>
<p>A recursive style also reduces the scope for off-by-one errors.</p>
<p>And now for an example that ties it together:</p>
<pre style="font-size:14px;">
rk4(
  (t, y) =&gt; 4 * Math.exp(0.8 * t) - 0.5 * y,
  0, 2, 10, 0.1)
</pre>
<p>I think anyone coming from a Java background will agree that passing around functions like this is lovely: goodbye interfaces and lots of curly braces, hello Functional Programming.</p>
<br /> Tagged: coding, scala <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/86/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/86/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/86/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=86&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/08/27/rk4-in-scala/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>Launch of Two New Sites</title>
		<link>http://colinhowe.wordpress.com/2009/08/20/launch-of-two-new-sites/</link>
		<comments>http://colinhowe.wordpress.com/2009/08/20/launch-of-two-new-sites/#comments</comments>
		<pubDate>Thu, 20 Aug 2009 18:17:21 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=77</guid>
		<description><![CDATA[Today I see the launch of two sites of mine that I&#8217;ve been working on in my free time over the past month or so. Neither of them are finished and well polished, but, the act of getting them out there will ensure I start taking them more seriously and start getting them used So, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=77&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Today I see the launch of two sites of mine that I&#8217;ve been working on in my free time over the past month or so. Neither of them are finished and well polished, but, the act of getting them out there will ensure I start taking them more seriously and start getting them used <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>So, I am proud to present: <a href="http://www.nogreensheep.com">No Green Sheep</a> and <a href="http://www.self-review.com/">Self-review.com</a>.</p>
<h3>No Green Sheep</h3>
<p>
The idea behind this site is to promote being more green and friendly to our planet &#8211; but by understanding the effects of our actions instead of just doing whatever someone tells us.
</p>
<p>The inspiration for this was a friend boiling a kettle on a gas hob and telling me it was more eco-friendly than boiling in an electric kettle. I asked &#8220;how?&#8221; and they couldn&#8217;t explain or give any numbers&#8230; unsurprisingly, I haven&#8217;t changed my kettle boiling habits. If my friend had known a few more details about this then she might well have had a convert out of me!</p>
<h3>Self-review.com</h3>
<p>
When I worked at <a href="http://www.chpconsulting.co.uk">CHP Consulting</a> I kept a monthly reminder in Outlook telling me to review how I&#8217;ve done over the past month. This process of self-reflection allowed me to move forward and improve myself in a positive manner. It also gave me complete ownership of it &#8211; it&#8217;s far better to set your own goals and achieve them than have someone else do it for you.
</p>
<p>
After leaving CHP I no longer had Outlook. I also decided I needed something a little more guided &#8211; something I could just tick a box to say I&#8217;d done what I wanted to do. I also wanted to gain feedback from my friends whenever possible (a <a href="http://colinhowe.wordpress.com/2009/06/10/how-i-have-failed-lessons-from-my-first-four-months-of-a-startup/">self-criticising blog post</a> of mine made me realise I wanted this). So, I made self-review.com. The commenting isn&#8217;t yet ready &#8211; but I&#8217;ll keep you posted!
</p>
<p>My first review of myself is available at <a href="http://www.self-review.com/reviews/5">http://www.self-review.com/reviews/5</a>
</p>
<h3>Twitter Accounts for Both</h3>
<p>If you want to keep up-to-date with both of these projects then they have their own Twitter accounts: <a href="http://twitter.com/selfreview">selfreview</a> and <a href="http://twitter.com/nogreensheep">nogreensheep</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/77/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/77/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/77/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=77&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/08/20/launch-of-two-new-sites/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>Why We Made Our Own Bug Tracker</title>
		<link>http://colinhowe.wordpress.com/2009/08/11/why-we-made-our-own-bug-tracker/</link>
		<comments>http://colinhowe.wordpress.com/2009/08/11/why-we-made-our-own-bug-tracker/#comments</comments>
		<pubDate>Tue, 11 Aug 2009 18:15:15 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>
		<category><![CDATA[startup]]></category>
		<category><![CDATA[bug tracker]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[custom]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=72</guid>
		<description><![CDATA[Part of starting the development of Sonnet Models was choosing a bug tracker. Knowing that reinventing the wheel was a bad thing I decided that we should do it anyway. Why would I do this? Knowing full-well of the existence and having used numerous bug trackers I decided that they all suffered from one common [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=72&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Part of starting the development of <a href="http://www.sonnetmodels.com">Sonnet Models</a> was choosing a bug tracker. Knowing that reinventing the wheel was a bad thing I decided that we should do it anyway.</p>
<p>Why would I do this? Knowing full-well of the existence and having used numerous bug trackers I decided that they all suffered from one common flaw: bloat.</p>
<h3>Bloated with Fluff-Fields</h3>
<p>If entering a bug requires more than 20 seconds of entering other fluff (such as priority, origin, area, etc etc) then small bugs will simply not get entered most of the time because it takes too long. It&#8217;s hard to admit that people are lazy but I&#8217;ve seen it happen too many times, &#8220;I&#8217;ll just add this bug onto this other issue to avoid trying to remember what to put in field X&#8221;.</p>
<p>I also believe that people tend to rush filling in such fluff-fields and the result is that much of the data is junk.</p>
<h3>What do we Track?</h3>
<p>In our bug tracker we have nine fields per bug.</p>
<p>Three of these are automatically generated and cannot be modified (created date, creator, modified date).</p>
<p>The other six are: type (bug, feature or admin task), summary, details, timebox, status (created, ready for testing, pending release, closed) and assignee. That&#8217;s it. I&#8217;m even considering binning the type field as we rarely use it (fortunately it defaults to bug so there isn&#8217;t an admin overhead here).</p>
<p>We allow commenting &#8211; but there is only one field &#8211; comment.</p>
<h3>Drawback &#8211; No Sexy Reporting</h3>
<p>Sure, I can&#8217;t query the bugs database to see the most common origin of bugs, but, as a start-up we have a very good feel for this and knowing the exact numbers wouldn&#8217;t justify the cost in time of collecting this data.</p>
<p>I also feel that the lack of sexy reporting is an advantage &#8211; I don&#8217;t spend half my afternoon trawling through meaningless reports looking for imaginary trends!</p>
<h3>Question for Large Companies</h3>
<p>Do you actually get any use from all the random data you collect? Or is it slowing you down? Are bugs slipping the net because people don&#8217;t want to have the burden of reporting bugs? (Or the e-mail deluge that normally follows from reporting a bug).</p>
<p>Avoiding the fluff is a hard task and sometimes we should learn to just say &#8220;no, we can&#8217;t add a field onto our bug reports saying what coffee the reporter was drinking at the time&#8221;.</p>
<h3>Agile Zen</h3>
<p>I&#8217;d like to finish this post by mentioning a new tracker: <a href="http://www.agilezen.com">Agile Zen</a>. This is an immensely light weight tracker and if it had commenting&#8230; we&#8217;d switch over as quickly as possible!</p>
<br /> Tagged: bug tracker, bugs, custom <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/72/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=72&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/08/11/why-we-made-our-own-bug-tracker/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>HtmlUnit &#8211; How to do a POST</title>
		<link>http://colinhowe.wordpress.com/2009/06/24/htmlunit-how-to-do-a-post/</link>
		<comments>http://colinhowe.wordpress.com/2009/06/24/htmlunit-how-to-do-a-post/#comments</comments>
		<pubDate>Wed, 24 Jun 2009 09:24:55 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>
		<category><![CDATA[htmlunit]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[testing]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=68</guid>
		<description><![CDATA[Background I&#8217;ve just started using HtmlUnit (I also use Selenium but find it too slow for 90% of my testing). HtmlUnit is generally easy to work with. Generally, it doesn&#8217;t need documentation as the Javadoc is useful and the methods are obvious. However, this is not the case for POST&#8230; so, here is how you [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=68&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h3>Background</h3>
<p>I&#8217;ve just started using HtmlUnit (I also use Selenium but find it too slow for 90% of my testing).</p>
<p>HtmlUnit is generally easy to work with. Generally, it doesn&#8217;t need documentation as the Javadoc is useful and the methods are obvious. However, this is not the case for POST&#8230; so, here is how you do a POST <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<h3>How to do a POST in HtmlUnit</h3>
<p>There really isn&#8217;t much to it &#8211; you just need to know what code to use:</p>
<pre style="font-size:1.2em;">
final WebClient webClient = new WebClient();

// Instead of requesting the page directly we create a WebRequestSettings object
WebRequestSettings requestSettings = new WebRequestSettings(
  new URL("URL GOES HERE"), HttpMethod.POST);

// Then we set the request parameters
requestSettings.setRequestParameters(new ArrayList());
requestSettings.getRequestParameters().add(new NameValuePair("name of value to post", "value"));

// Finally, we can get the page
HtmlPage page = webClient.getPage(requestSettings);
</pre>
<p>Quite a lot of work for a simple&#8230; I imagine it won&#8217;t be hard to wrap this up into a neat POST method.</p>
<br /> Tagged: htmlunit, java, testing <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/68/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=68&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/06/24/htmlunit-how-to-do-a-post/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>I feel good! (Follow-up on Lessons Learned!)</title>
		<link>http://colinhowe.wordpress.com/2009/06/17/i-feel-good-follow-up-on-lessons-learned/</link>
		<comments>http://colinhowe.wordpress.com/2009/06/17/i-feel-good-follow-up-on-lessons-learned/#comments</comments>
		<pubDate>Wed, 17 Jun 2009 16:27:45 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=66</guid>
		<description><![CDATA[I feel good. I am more productive and happier in my life. Why? I&#8217;m working less. Why? The conclusion of my previous blog post was that I should try to work less. So, I&#8217;ve been forcing myself to ~7-8 hours every day. Working less but getting more done? Yes. I am motivated because I have [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=66&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I feel good. I am more productive and happier in my life.</p>
<p>Why?</p>
<p>I&#8217;m working <em>less</em>.</p>
<p>Why?</p>
<p>The conclusion of my <a title="previous blog post" href="http://colinhowe.wordpress.com/2009/06/10/how-i-have-failed-lessons-from-my-first-four-months-of-a-startup/">previous blog post</a> was that I should try to work less. So, I&#8217;ve been forcing myself to ~7-8 hours every day.</p>
<p>Working less but getting more done?</p>
<p>Yes. I am motivated because I have had time to relax and reflect.</p>
<p>Win?</p>
<p>You bet.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/66/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/66/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/66/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=66&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/06/17/i-feel-good-follow-up-on-lessons-learned/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>How I Have Failed &#8211; Lessons From My First Four Months of a Startup</title>
		<link>http://colinhowe.wordpress.com/2009/06/10/how-i-have-failed-lessons-from-my-first-four-months-of-a-startup/</link>
		<comments>http://colinhowe.wordpress.com/2009/06/10/how-i-have-failed-lessons-from-my-first-four-months-of-a-startup/#comments</comments>
		<pubDate>Wed, 10 Jun 2009 21:24:06 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[startup]]></category>
		<category><![CDATA[fail]]></category>
		<category><![CDATA[reflection]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=59</guid>
		<description><![CDATA[Over the past few days I have taken some time to reflect on the previous few months and think about how I have failed in various ways and also how I have done well As some of you will know I left my job in February to become the technical director in an early stage [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=59&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Over the past few days I have taken some time to reflect on the previous few months and think about how I have failed in various ways and also how I have done well <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>As some of you will know I left my job in February to become the technical director in an early stage startup (actually I do everything technical and also a bit of the business work &#8211; that&#8217;s the joy of a small team!). Since then we&#8217;ve done a lot of great work, but I have also done my fair share of things that should now be thought of as learning opportunities. I&#8217;m going to take some time to go over a few of them as I think I&#8217;m not alone in making these mistakes!</p>
<p><strong>Disclaimer: This is a bit of a brain dump &#8211; mostly self-indulgence for me in actually straightening out my thoughts!</strong></p>
<h3>Not Pausing For Reflection</h3>
<p>It&#8217;s taken me four months to sit back and go &#8220;Are we doing this right? How am I behaving? What should I be changing?&#8221;. Sure, I&#8217;ve paid lip service to doing this but I&#8217;ve not properly sat down and given it serious thought. This is <strong>far</strong> too long to go without doing this &#8211; I&#8217;m confident I would be guilty of committing fewer of my sins below if I had done this.</p>
<p>So, I&#8217;m now going to sit down once a month and have a good think <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<h3>Not Releasing Quick Enough</h3>
<p>The product that we are developing is now in a public beta and we&#8217;re about to go for a big launch. We could have launched a few months ago with fewer bells and whistles. This would have given us far more time to listen to what people are saying instead of guessing and making a few mistakes. On the flip side, we could have wasted our opportunity to build momentum as people saw it and thought &#8220;this is rubbish&#8221;. However, that doesn&#8217;t seem to have been a problem for Facebook, MySpace, Twitter, etc&#8230; I think that most people these days are quite happy to accept an evolving service &#8211; so long as it isn&#8217;t breaking. I also think this is a good way to build and sustain hype &#8211; people talk about new features / design tweaks.</p>
<h3>Not Treating Close Friends with Sufficient Respect</h3>
<p>This is a haenous crime and I apologise to everyone who has been on the receiving end of this.</p>
<p>As my startup is basically my life I&#8217;ve told my closest friends quite a lot about it. This means that when they later talk to me I forget that they aren&#8217;t as absorbed as I am and don&#8217;t know my reasoning behind things when I shoot down a suggestion from them. A typical conversation might go:</p>
<p style="padding-left:30px;">Them: I think you should do X</p>
<p style="padding-left:30px;">Me: That won&#8217;t work. The demand isn&#8217;t there for it.</p>
<p>And I&#8217;ll try to end the conversation there. Bad idea. Often the idea is a great idea there is just some nuance of the business that makes it inapplicable in our case. I should thank them for their idea and explain to them my reasoning for any bold statement about the idea.</p>
<h3>Optimising Early</h3>
<p>Guilty. I did some scaling testing and scalability was OK&#8230; but I wanted more bang for our buck. This is the sort of thing that (provided you know how you&#8217;re going to do it) can be done later when you&#8217;ve actually proven the business is meeting a demand.</p>
<h3>Working Too Much</h3>
<p>It&#8217;s very easy to get absorbed into your very own startup. So easy that I have ended up spending a lot of time either working on it or doing things very closely related. The result: friendships suffer, my concentration suffers and my ability to make good decisions becomes less&#8230; good. I&#8217;m now setting a rule of no work after 8pm and preferably no work after 6pm <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<h3>Not Networking Enough</h3>
<p>I&#8217;ve blamed this on moving away from London and the time it takes to commute there and back. In truth, I&#8217;m lazy and I&#8217;ve been working too much. If I&#8217;m sensible about how I work then I can easily get myself to some good events, have a good time and meet some great people!</p>
<p>I&#8217;m going to start making myself get to at least one event a month&#8230; am open to fun suggestions in London!</p>
<h3>Allowed Things to Drag</h3>
<p>Certain business decisions we&#8217;ve made have been allowed to drag on for far too long. We&#8217;ve tried to be clever about it and get the best timing, make the best decision etc etc&#8230; but I think this has been us covering up for indecision. If we don&#8217;t know how to make a decision we should be thinking about what we need to know to make that decision.</p>
<p>I&#8217;m going to start forcing decisions &#8211; or forcing gathering the knowledge we need &#8211; or developing an action plan for getting <em>somewhere</em> with the decision</p>
<h3>Not Blogging Enough</h3>
<p>This is a similar point to the reflection point. The act of blogging is a great way for me to get my thoughts out and clear my mind. I can then focus far better afterwards!</p>
<p>I&#8217;m going to try to blog once a week</p>
<h2>My Focus For Personal Development</h2>
<p>I know it&#8217;s hard to improve several things at once&#8230; so, I&#8217;m going to focus on not working too hard and hope the rest falls into place. In a months time we&#8217;ll see where I have got!</p>
<h2>One last thing&#8230; The Good?</h2>
<p>To summarise the good: we&#8217;ve developed a really neat looking product that we&#8217;re proud of it. I&#8217;m proud of it <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  I&#8217;ll share it with you all soon! (I realise I&#8217;m continuing to violate &#8220;not releasing quick enough&#8221; but there&#8217;s only a few days left till we launch so might as well hold on!)</p>
<br /> Tagged: fail, reflection, startup <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/59/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=59&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/06/10/how-i-have-failed-lessons-from-my-first-four-months-of-a-startup/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>Windows 7 (World) vs Ubuntu 9.04 Jaunty (World) for a developer</title>
		<link>http://colinhowe.wordpress.com/2009/05/20/my-ubuntu-experience/</link>
		<comments>http://colinhowe.wordpress.com/2009/05/20/my-ubuntu-experience/#comments</comments>
		<pubDate>Wed, 20 May 2009 21:55:05 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>
		<category><![CDATA[comparison]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[windows]]></category>
		<category><![CDATA[windows7]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=46</guid>
		<description><![CDATA[Background This initially started of as a blog posting about how wonderful Ubuntu is for a developer and the various pitfalls I found. However, since installing Ubuntu and initially being wowed I have gone back to Windows. So, I thought I&#8217;d offer up my thoughts as to why I made this decision. For the record: [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=46&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h3><strong>Background</strong></h3>
<p>This initially started of as a blog posting about how wonderful Ubuntu is for a developer and the various pitfalls I found. However, since installing Ubuntu and initially being wowed I have gone back to Windows. So, I thought I&#8217;d offer up my thoughts as to why I made this decision.</p>
<p>For the record: I still use Ubuntu on my laptop because some of my problems with Ubuntu aren&#8217;t evident on my laptop. I do also have Windows on dual-boot for the times I need it.</p>
<h3>This is not Windows vs Ubuntu</h3>
<p>The (world) in the title is a hint. I am comparing my world when running Windows  against my world when running Ubuntu. This means that I am looking at not just the operating system but how I can go about doing everything that I do (mostly development work with a bit of gaming thrown in)</p>
<h3>Ubuntu &#8211; The Good</h3>
<p>So, what makes the Ubuntu experience better than Windows?</p>
<ul>
<li>Out the box support for multiple desktops
<ul>
<li>That said, the apps for Windows that do multiple desktops are much more stable than a few years ago</li>
</ul>
</li>
<li>Customisation of&#8230; everything
<ul>
<li>For example, on my laptop I have compiz set up to remove title bars from maximised windows &#8211; screen estate is valuable on a laptop</li>
</ul>
</li>
<li>Automatic updates for everything
<ul>
<li>Nearly everything I install I use apt for. This then means it gets auto-updated with new features / bug fixes</li>
<li>Nearly everything in Windows has its own update manager&#8230; and I kill most of them as I don&#8217;t want them running all the time</li>
</ul>
</li>
</ul>
<p>Ubuntu being free isn&#8217;t such a winner for me &#8211; it only adds to the experience when you first install it and you don&#8217;t continuously feel the benefits</p>
<h3>Ubuntu &#8211; The Bad</h3>
<p>And&#8230; what makes the Ubuntu experience worse?</p>
<ul>
<li>Initial fonts (in my opinion) are horrible
<ul>
<li>This isn&#8217;t really Ubuntu&#8217;s fault. Many websites are designed using Windows fonts and due to licencing the fonts can&#8217;t be installed by default</li>
<li>Solution: install <a href="http://ubuntu.wordpress.com/2005/09/09/installing-microsoft-fonts/">windows font pack</a> and various other bits and pieces</li>
</ul>
</li>
<li>GIMP. I&#8217;m not a designer. I want to take screenshots, resize them and draw cirlces / boxes around things. I don&#8217;t want to learn anything new to do this
<ul>
<li>GIMP by default is the equivalent of using Adobe Photoshop by default &#8211; it&#8217;s a powerful tool but not the right tool for my simple tasks</li>
<li>In Windows, Paint.net is exactly the right tool for 99% of the image editing I do, and, I haven&#8217;t had to spend time learning it</li>
</ul>
</li>
<li>Dual-screen support
<ul>
<li>This was a huge chore to get working right in Ubuntu &#8211; it defaulted my left monitor as my primary monitor and setting it otherwise was non-trivial</li>
</ul>
</li>
<li>User interface sluggish
<ul>
<li>After doing some reading it seems my ATI card is to blame</li>
</ul>
</li>
<li>ATI drivers
<ul>
<li>Couldn&#8217;t get these working&#8230; but installing/uninstalling them was a lot of grief &#8211; if ATI want me to buy another ATI card then they need to support Ubuntu better (I hear NVidia has far better support)</li>
</ul>
</li>
<li>SQLYog doesn&#8217;t work as nicely in Wine as it does in Windows and I couldn&#8217;t find a linux alternative</li>
<li>No equivalent to TortoiseSVN</li>
<li>Customisation of&#8230; everything
<ul>
<li>A blessing and a curse. I spent far more time than is healthy playing around with things <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
</ul>
</li>
<li>Gaming
<ul>
<li>I play Team Fortress 2 to unwind &#8211; it&#8217;s not as simple to get started as it is in Windows</li>
</ul>
</li>
</ul>
<h3>Conclusion</h3>
<p>So, what made me can the Ubuntu experiment? Dual screens and the sluggish reponse. These are the only things that affected me on a continual basis, everything else I could deal with.</p>
<p>In defence of Ubuntu: most of the problems are not the problem of the OS but a lack of support from other people and a lack of linux equivalents to my favourite Windows programs.</p>
<p>I hope this is of some use to anyone with a similar lifestyle when deciding what OS to use <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  As always, comments are welcome!</p>
<br /> Tagged: comparison, ubuntu, windows, windows7 <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/46/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/46/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/46/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/46/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/46/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/46/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/46/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/46/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=46&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/05/20/my-ubuntu-experience/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>Redis vs MySQL vs Tokyo Tyrant (on EC2)</title>
		<link>http://colinhowe.wordpress.com/2009/04/27/redis-vs-mysql/</link>
		<comments>http://colinhowe.wordpress.com/2009/04/27/redis-vs-mysql/#comments</comments>
		<pubDate>Mon, 27 Apr 2009 18:28:43 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>
		<category><![CDATA[key-value store]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[redis]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=39</guid>
		<description><![CDATA[Update (28th April 2009) &#8211; Added Tokyo Tyrant What is Redis? Briefly, Redis is a key-value store that stores the values to disk periodically instead of after every set. What is Tokyo Tyrant? Tokyo Tyrant is similar to Redis &#8211; a key-value store. Aim This is a brief comparison of the performance of Redis and [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=39&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h2><strong>Update (28th April 2009) &#8211; Added Tokyo Tyrant<br />
</strong></h2>
<h2></h2>
<h2>What is Redis?</h2>
<p>Briefly, <a title="Redis" href="http://code.google.com/p/redis/">Redis</a> is a key-value store that stores the values to disk periodically instead of after every set.</p>
<h2>What is Tokyo Tyrant?</h2>
<p><a href="http://tokyocabinet.sourceforge.net/tyrantdoc/">Tokyo Tyrant</a> is similar to Redis &#8211; a key-value store.</p>
<h2></h2>
<h2>Aim</h2>
<p>This is a brief comparison of the performance of Redis and MySQL. It is not very thorough and is only to be used as an indication as to whether Redis may be worth your further investigation.</p>
<p>After a brief search I failed to find any performance comparisons of Redis and MySQL to determine if it was even worth my time looking at Redis. I appreciate they are very different beasts but in our database we have a lot of data that would fit very nicely into a key-value store.</p>
<p>So, the question I am trying to answer is &#8220;roughly how much performance can we gain from using Redis for storing simple data instead of MySQL?&#8221;. Then it is up to you to look at all the differences and decide whether it is worth pursuing a switch to Redis.</p>
<p>Note: I will be looking at other key-value stores in the near future <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<h2>The Test</h2>
<p>The two tests performed are:</p>
<ul>
<li>Using 2 threads: set X items with the keys/values being consecutive numbers</li>
<li>Using 2 threads: randomly get these items Y times</li>
</ul>
<h2>Setup</h2>
<ol>
<li>EC2 small instance.</li>
<li>Default install of MySQL with a single InnoDB table for storing keys and values.</li>
<li>Default make of Redis.</li>
<li>Small Java benchmark programs sitting on the same box</li>
</ol>
<h2>Source Code</h2>
<p>The numbers in these files are not the exact numbers I used (apart from using two client threads in both tests)</p>
<ol>
<li>Redis benchmark: <a href="http://pastebin.com/f5adb41b0">http://pastebin.com/f5adb41b0</a></li>
<li>MySQL benchmark: <a href="http://pastebin.com/m52fd35d1">http://pastebin.com/m52fd35d1</a></li>
</ol>
<h2>Results</h2>
<h3>Mysql</h3>
<p>3,030 sets/second.</p>
<p>4,670 gets/second.</p>
<h3>Redis (In-memory only)</h3>
<p>11,200 sets/second. (3.7x MySQL)</p>
<p>9,840 gets/second. (2.1x MySQL)</p>
<h3>Tokyo Tyrant (Writing to disk)</h3>
<p>9,030 sets/second. (3.0x MySQL)</p>
<p>9,250 gets/second. (2.0x MySQL)</p>
<h2>Thoughts</h2>
<p>Key-value stores are generally going to be faster than MySQL. They (generally) provide less functionality in the way of querying arbitrary columns and ACID compliance. This translates into faster performance on gets/sets.</p>
<p>Once again, it is worth pointing out that this is a very simple benchmark. My suspicion is that when you have lots of cross updates going on then Redis/Tyrant will have a greater performance boost over MySQL &#8211; but at the cost of transactionality.</p>
<p>My suspicion is that as the technology matures we are going to start seeing a big shift towards using key-value stores as the first port of call for data storage for websites. I expect it won&#8217;t be long before we start seeing hosts offering LAKP (Linux, Apache, a key-value store, PHP) as well as the more traditional LAMP offerings.</p>
<p>I would love to hear from anyone with real world experience and numbers of switching over to Redis&#8230; until I have some of my own to share anyway <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<br /> Tagged: key-value store, mysql, redis <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/39/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/39/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/39/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/39/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/39/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/39/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/39/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/39/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=39&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/04/27/redis-vs-mysql/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>C3P0: Tried to check-in a foreign resource!</title>
		<link>http://colinhowe.wordpress.com/2009/03/25/c3p0-tried-to-check-in-a-foreign-resource/</link>
		<comments>http://colinhowe.wordpress.com/2009/03/25/c3p0-tried-to-check-in-a-foreign-resource/#comments</comments>
		<pubDate>Wed, 25 Mar 2009 14:34:45 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>
		<category><![CDATA[c3p0]]></category>
		<category><![CDATA[exception]]></category>
		<category><![CDATA[hibernate]]></category>
		<category><![CDATA[java]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=31</guid>
		<description><![CDATA[Earlier today I encountered the following stack trace whilst using C3P0 and Hibernate: com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool - An Exception occurred while trying to check a PooledConection into a ResourcePool. com.mchange.v2.resourcepool.ResourcePoolException: ResourcePool [BROKEN!]: Tried to check-in a foreign resource! at com.mchange.v2.resourcepool.BasicResourcePool.checkinResource(BasicResourcePool.java:657) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$ConnectionEventListenerImpl.doCheckinResource(C3P0PooledConnectionPool.java:636) at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$ConnectionEventListenerImpl.connectionClosed(C3P0PooledConnectionPool.java:630) at com.mchange.v2.c3p0.util.ConnectionEventSupport.fireConnectionClosed(ConnectionEventSupport.java:55) at com.mchange.v2.c3p0.impl.NewPooledConnection.fireConnectionClosed(NewPooledConnection.java:510) at com.mchange.v2.c3p0.impl.NewPooledConnection.markClosedProxyConnection(NewPooledConnection.java:381) at com.mchange.v2.c3p0.impl.NewProxyConnection.close(NewProxyConnection.java:1246) at org.hibernate.connection.C3P0ConnectionProvider.closeConnection(C3P0ConnectionProvider.java:92) at org.hibernate.jdbc.ConnectionManager.closeConnection(ConnectionManager.java:474) at [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=31&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Earlier today I encountered the following stack trace whilst using C3P0 and Hibernate:</p>
<pre style="font-size:1.2em;overflow:scroll;">
com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool - An Exception occurred while trying to check a PooledConection into a ResourcePool.
com.mchange.v2.resourcepool.ResourcePoolException: ResourcePool [BROKEN!]: Tried to check-in a foreign resource!
	at com.mchange.v2.resourcepool.BasicResourcePool.checkinResource(BasicResourcePool.java:657)
	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$ConnectionEventListenerImpl.doCheckinResource(C3P0PooledConnectionPool.java:636)
	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$ConnectionEventListenerImpl.connectionClosed(C3P0PooledConnectionPool.java:630)
	at com.mchange.v2.c3p0.util.ConnectionEventSupport.fireConnectionClosed(ConnectionEventSupport.java:55)
	at com.mchange.v2.c3p0.impl.NewPooledConnection.fireConnectionClosed(NewPooledConnection.java:510)
	at com.mchange.v2.c3p0.impl.NewPooledConnection.markClosedProxyConnection(NewPooledConnection.java:381)
	at com.mchange.v2.c3p0.impl.NewProxyConnection.close(NewProxyConnection.java:1246)
	at org.hibernate.connection.C3P0ConnectionProvider.closeConnection(C3P0ConnectionProvider.java:92)
	at org.hibernate.jdbc.ConnectionManager.closeConnection(ConnectionManager.java:474)
	at org.hibernate.jdbc.ConnectionManager.aggressiveRelease(ConnectionManager.java:429)
	at org.hibernate.jdbc.ConnectionManager.afterTransaction(ConnectionManager.java:316)
	at org.hibernate.jdbc.JDBCContext.afterNontransactionalQuery(JDBCContext.java:268)
	at org.hibernate.impl.SessionImpl.afterOperation(SessionImpl.java:444)
	at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1153)
	at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102)
</pre>
<p><em>Apologies for the scroll bars&#8230; but hopefully this is indexed neatly by Google to help others!</em></p>
<p>After a bit of investigation it turned out this was due to a multi-threading issue and the solution can be summarised quite neatly:</p>
<p><strong>never shut down Hibernate before all threads have finished what they&#8217;re doing (if they are using Hibernate)</strong></p>
<p>Otherwise, you may get the above exception (or an equally unhelpful exception).</p>
<br /> Tagged: c3p0, exception, hibernate, java <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/31/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=31&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/03/25/c3p0-tried-to-check-in-a-foreign-resource/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
		<item>
		<title>How I Test and Tweak CSS for Cross-Browser Compatibility</title>
		<link>http://colinhowe.wordpress.com/2009/03/11/how-i-test-and-tweak-css-for-cross-browser-compatibility/</link>
		<comments>http://colinhowe.wordpress.com/2009/03/11/how-i-test-and-tweak-css-for-cross-browser-compatibility/#comments</comments>
		<pubDate>Wed, 11 Mar 2009 21:57:33 +0000</pubDate>
		<dc:creator>colinhowe</dc:creator>
				<category><![CDATA[Coding / Tech]]></category>

		<guid isPermaLink="false">http://colinhowe.wordpress.com/?p=23</guid>
		<description><![CDATA[Motivation Why bother supporting more than one browser? For anyone wanting to hit a large proportion of the population then supporting Firefox 2, Firefox 3, Internet Explorer 6 and Internet Explorer 7 are necessary to satisfy 89% of the market (browser stats). It may also be desirable to support Chrome and Safari to get to [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=23&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h2>Motivation</h2>
<p>Why bother supporting more than one browser? For anyone wanting to hit a large proportion of the population then supporting Firefox 2, Firefox 3, Internet Explorer 6 and Internet Explorer 7 are necessary to satisfy 89% of the market (<a href="http://www.w3schools.com/browsers/browsers_stats.asp">browser stats</a>). It may also be desirable to support Chrome and Safari to get to 96%.</p>
<p>That is a lot of platforms &#8211; all with their own behaviours and interpretations of specifications. I&#8217;ll ignore arguments about upgrading browsers / converging on one/two browsers as that is a big topic that is regularly argued about the world over.</p>
<p>So, here is how I cope with the joy of cross-browser compatibility</p>
<h2>Testing</h2>
<p>Before we can fix something we need to know it is broken. The approach I take is to try out the web site on all the browsers I want the site to work on &#8211; unfortunately, it&#8217;s not that simple to have all possible browsers on one machine.</p>
<h3>Firefox 3 and Internet Explorer 7</h3>
<p>These two are easy &#8211; I have them installed all the time on my development machine. They co-exist quite peacefully and give me no grief.</p>
<h3>Firefox 2</h3>
<p>Firefox 2 can be completely standalone as a portable app. Stick it in a folder and run it, at the same time as FF3. <a href="http://www.whatwasithinking.co.uk/2008/06/26/on-web-development-how-to-install-firefox-2-next-to-firefox-3/">Here&#8217;s how</a></p>
<h3>Internet Explorer 6</h3>
<p>Rumour has it that you can install Internet Explorer 6 as a standalone application. I&#8217;ve had no luck with this approach. My approach is to use a virtual PC. Microsoft have kindly made Virtual PC 2007 available for free <a href="http://www.microsoft.com/windows/downloads/virtualpc/default.mspx">here</a>. They also provide images for the common setups <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=7c2b5317-a40f-4e86-8835-d37170c5923e&amp;displaylang=en">here</a>.</p>
<h3>Safari</h3>
<p>This is available from Apple as a download for the PC, <a href="http://www.apple.com/safari/download/">here</a>. </p>
<h2>Tweaking for Compatibility</h2>
<p>So, we&#8217;ve now identified a problem with our site in one of the browsers. Searching the internet will usually reveal the necessary tweak for that browser. There are also countless tricks out there for making our CSS only appear to a particular browser. Such as:</p>
<p><code><br />
/* Hide from IE-Mac \*/<br />
#header {margin-bottom:3em}<br />
#footer {margin-top:1.5em}<br />
/* End hide */<br />
</code></p>
<p>I generally don&#8217;t like these approaches as they obfuscate our CSS to some extent, this then leads to mistakes. So, what do I prefer?</p>
<p>Browser specific CSS in browser specific files. For any of my sites my stylesheets will generally look like:</p>
<ul>
<li>default.css &#8211; included by all browsers for the core style</li>
<li>ie6.css &#8211; included only by Internet Explorer 6</li>
<li>ie7.css &#8211; included only by Internet Explorer 7</li>
<li>ff2.css &#8211; included only by Firefox 2</li>
<li>Firefox 3 is omitted as I develop in Firefox 3 so that all stays in default.css</li>
</ul>
<p>The important thing here is that the browser specific files are included <b>after</b> the default. This allows me to specify that a div shouldn&#8217;t be a float but instead should use relative positioning or whatever specific tweak is needed.</p>
<p>I feel that this yields much clearer CSS than the hack approach and is hence more maintainable. This also allows us to completely overhaul a design for a particular browser if it is giving us substantial grief. The disadvantages to this approach are that it increases the number of files to maintain. </p>
<p>My personal view is that I would rather have 4 clear and easy to maintain files rather than 1 hard to maintain file. </p>
<p>Implementing this is fairly easy in most systems. In PHP we can use $_SERVER['HTTP_USER_AGENT'] to get to it. We can even use Javascript / AJAX to do this.</p>
<p>But, isn&#8217;t this unreliable? Couldn&#8217;t a user fake this? (Or, a firewall). Sure. However, we&#8217;re trying to be pragmatic here &#8211; we can&#8217;t get a complex page to work 100% reliably on all browsers without doing CSS tricks so we have to do something that is maintainable.</p>
<p>If we keep as much as possible in the core stylesheet then the user shouldn&#8217;t have a terrible experience if their browser is mis-reported and so we shouldn&#8217;t be losing too many visitors to bad browser detection. We can even go one step further and ensure that the core style sheet gives a good (not perfect) view of the page in every browser without additional tweaking&#8230; then layer the tweaks on top!</p>
<h2>Disclaimer</h2>
<p>In the above I have outlined a method that may or may not be appropriate for your situation. If you have a little site with one page, a simple layout but it doesn&#8217;t work in all browsers then you&#8217;re probably better off using hacks. If you have a big site with lots of pages and a complex layout then you may want to consider layering your stylesheets.</p>
<p>As with all software development &#8211; use your brain. Read around. Make the decisions that are right for your project &#8211; never use a fork to eat soup.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/colinhowe.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/colinhowe.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/colinhowe.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/colinhowe.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/colinhowe.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/colinhowe.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/colinhowe.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/colinhowe.wordpress.com/23/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=colinhowe.wordpress.com&amp;blog=6742552&amp;post=23&amp;subd=colinhowe&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://colinhowe.wordpress.com/2009/03/11/how-i-test-and-tweak-css-for-cross-browser-compatibility/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/c40ff67db5b5a313a6705e03992e55eb?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">Colin Howe</media:title>
		</media:content>
	</item>
	</channel>
</rss>
