<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>http://morethanseven.net/</id>
  <title>Morethanseven Articles</title>
  <updated>2010-03-08T00:00:00Z</updated>
  <link rel="alternate" href="http://morethanseven.net/"/>
  <link rel="self" href="http://morethanseven.net/articles.rss"/>
  <author>
    <name>Gareth Rushgrove</name>
    <uri>http://morethanseven.net</uri>
  </author>
  <entry>
    <id>tag:morethanseven.net,2010-03-08:/2010/03/08/Piston-and-sanitising-json-callbacks.html</id>
    <title type="html">Piston And Sanitising Json Callbacks</title>
    <published>2010-03-08T00:00:00Z</published>
    <updated>2010-03-08T21:03:59Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/03/08/Piston-and-sanitising-json-callbacks.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;m a big fan of &lt;a href="http://bitbucket.org/jespern/django-piston"&gt;Piston&lt;/a&gt;, the django app for creating RESTful web services. As part of a project at work I ended up looking through the source code, mainly at some of the neat tricks of serialisation of objects. While poking around I came across something in my mind that wanted fixing. This being open source rather than just file a bug report I setup a &lt;a href="http://bitbucket.org"&gt;bitbucket&lt;/a&gt; account and got hacking.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span class="kw"&gt;def&lt;/span&gt; &lt;span class="fu"&gt;render&lt;/span&gt;(&lt;span class="pc"&gt;self&lt;/span&gt;, request):
        cb = request.GET.get(&lt;span class="s"&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="k"&gt;callback&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;/span&gt;)
        seria = simplejson.dumps(&lt;span class="pc"&gt;self&lt;/span&gt;.construct(),
                cls=DateTimeAwareJSONEncoder,
                ensure_ascii=&lt;span class="pc"&gt;False&lt;/span&gt;, indent=&lt;span class="i"&gt;4&lt;/span&gt;)

        &lt;span class="c"&gt;# Callback&lt;/span&gt;
        &lt;span class="kw"&gt;if&lt;/span&gt; cb:
            &lt;span class="kw"&gt;return&lt;/span&gt; &lt;span class="s"&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="k"&gt;%s(%s)&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;/span&gt; % (cb, seria)

        &lt;span class="kw"&gt;return&lt;/span&gt; seria&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Can you spot the problem? Note the use of the callback passed in the query string arguments and then used &lt;em&gt;without any checking&lt;/em&gt; in the output.&lt;/p&gt;
&lt;p&gt;What we really want to do is something like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&lt;span class="kw"&gt;if&lt;/span&gt; is_valid_jsonp_callback_value(cb):&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Which is exactly what has just &lt;a href="http://bitbucket.org/jespern/django-piston/changeset/f558b2c66dcc/"&gt;gone into the code for Piston&lt;/a&gt;. &lt;a href="http://tav.espians.com/sanitising-jsonp-callback-identifiers-for-security.html"&gt;This article&lt;/a&gt; contains lots of background information about why &lt;span class="caps"&gt;JSONP&lt;/span&gt; callbacks can be a security hole, and helpfully provides a &lt;a href="http://github.com/tav/scripts/blob/master/validate_jsonp.py"&gt;nice Python module&lt;/a&gt; to help with the sanitisation. Nice to be on the authors list for something I&amp;#8217;m using actively.&lt;/p&gt;
&lt;p&gt;Thanks to &lt;a href="http://twitter.com/jespern"&gt;Jesper Noehr&lt;/a&gt; for Piston, for some pointers on bitbucket and for quickly taking the patch. If you&amp;#8217;re accepting a callback on your site or application, especially if it&amp;#8217;s a public service, you really want to do something like this or you just might have an exploitable security hole.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-03-07:/2010/03/07/New-nanoc-powered-blog.html</id>
    <title type="html">New Nanoc Powered Blog</title>
    <published>2010-03-07T00:00:00Z</published>
    <updated>2010-03-07T16:54:00Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/03/07/New-nanoc-powered-blog.html"/>
    <content type="html">&lt;p&gt;It&amp;#8217;s taken longer than I would have liked but I&amp;#8217;ve finally gotten around to relaunching this site on &lt;a href="http://nanoc.stoneship.org/"&gt;nanoc&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;After looking through lots of code from the &lt;a href="http://projects.stoneship.org/trac/nanoc/wiki/Showcase"&gt;nanoc showcase&lt;/a&gt; I had a pretty good feel for how I wanted things to work and I then used the excellent &lt;a href="http://github.com/mgutz/nanoc3_blog"&gt;nanoc3_blog&lt;/a&gt; template to get started. I&amp;#8217;ve hacked around quite a bit with the code to get things how I wanted them. Using &lt;a href="http://lesscss.org/"&gt;Less&lt;/a&gt; to make the &lt;span class="caps"&gt;CSS&lt;/span&gt; more manageable, &lt;a href="http://coderay.rubychan.de/"&gt;Coderay&lt;/a&gt; for lovely syntax highlighting and making everything default to textile rather than markdown. I&amp;#8217;ve also written import scripts for my old blog (in Python) and another one so I can use tumblr is I want to create items on here (in Ruby).&lt;/p&gt;
&lt;p&gt;Nanoc really is a joy to work with and I&amp;#8217;m hoping that alone will get me back into writing more freqently than I have done for a while. The fact I can just write in Vim or WriteRoom or whatever editor I have to hand feels nice. And using Git, Rake and Rsync complete my little toolset. Everything is still served via Nginx.&lt;/p&gt;
&lt;p&gt;I&amp;#8217;ve thrown the all the code, including all the content, up on &lt;a href="http://github.com/garethr/morethanseven"&gt;GitHub&lt;/a&gt; for anyone interested. Back to writing.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-03-07:/2010/03/07/Mysql-support-for-cucumber-nagios.html</id>
    <title type="html">Mysql Support For Cucumber Nagios</title>
    <published>2010-03-07T00:00:00Z</published>
    <updated>2010-03-07T17:25:24Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/03/07/Mysql-support-for-cucumber-nagios.html"/>
    <content type="html">&lt;p&gt;I just noticed Lindsay had &lt;a href="http://github.com/auxesis/cucumber-nagios"&gt;committed&lt;/a&gt; the amqp steps for cucumber-nagios and remembered I hadn&amp;#8217;t mentioned on here some other work I&amp;#8217;ve been doing on the same project. We use MySQL quite a bit at work and I&amp;#8217;ve been wanting to extent our monitoring for a while. So I set about thinking how that would work with cucumber-nagios. What I&amp;#8217;ve come up with looks something like this:&lt;/p&gt;
&lt;pre&gt;
Feature: localhost
  To make sure the rest of the system is in order
  Our database server should not be overloaded

  Scenario: check running processes count
    Given I have a MySQL server on localhost
    And I use the username root
    Then it should have less than 10 processes

  Scenario: check queries per second
    Given I have a MySQL server on localhost
    And I use the username root
    Then it should have less than 200 select queries per second
    Then it should have less than 300 queries per second
    Then it should have less than 5 slow queries pers second
    Then it should have at least 10 queries per second
&lt;/pre&gt;
&lt;p&gt;The numbers, username details and host details are all variables. So you can write senarios for your specific deployments. The tests over time are based on a very short lived sampling mechanic which I&amp;#8217;ve yet to test in anger. I&amp;#8217;m not sure just yet is this approach will lead to too many false positives but we&amp;#8217;ll have to see.&lt;/p&gt;
&lt;p&gt;This &lt;a href="http://codeinthehole.com/archives/8-Monitoring-MySQL-with-Ganglia-and-gmetric.html"&gt;mysql gmetric script&lt;/a&gt; gave me lots of the ideas for invidual steps. I&amp;#8217;ll be writing more about some work I&amp;#8217;ve been doing with cucumber-nagios and ganglia soon as well.&lt;/p&gt;
&lt;p&gt;For the moment if anyone want&amp;#8217;s to try these steps out you can either check out &lt;a href="http://github.com/garethr/cucumber-nagios"&gt;my cucumber-nagios&lt;/a&gt; fork or just grab the steps from the &lt;a href="http://github.com/garethr/cucumber-nagios/blob/master/lib/generators/project/features/steps/mysql_steps.rb"&gt;mysql_steps.rb&lt;/a&gt; file. Any feedback much appreciated.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-02-15:/2010/02/15/blogging-platforms.html</id>
    <title type="html">On blogging platforms</title>
    <published>2010-02-15T00:00:00Z</published>
    <updated>2010-03-07T16:59:24Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/02/15/blogging-platforms.html"/>
    <content type="html">&lt;p&gt;Every now and again I feel the need for a change and spent a little time tonight looking at different blogging software. I&amp;#8217;m currently running a custom django app I wrote a good while ago, more as an excuse to play with Django than anything. Previously I&amp;#8217;ve used Wordpress, Textpattern and even Radiant. But I&amp;#8217;m coming to the conclusion that what I want doesn&amp;#8217;t exist. In theory that means an opportunity for someone to enter the market, in reality I think it might just be me. So, what do I want?&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Customisable &lt;span class="caps"&gt;URL&lt;/span&gt; patterns and redirects. Tumblr did well until this point but I have years of content on nice URLs and I&amp;#8217;d not going to throw that away.&lt;/li&gt;
	&lt;li&gt;Command line interface for posting snippets&lt;/li&gt;
	&lt;li&gt;Nice looking web based &lt;span class="caps"&gt;API&lt;/span&gt; (bonus points to Typepad here for some nifty features like pubsubhubhub)&lt;/li&gt;
	&lt;li&gt;iPod touch app&lt;/li&gt;
	&lt;li&gt;Real control over the design, not just pre-made templates unless you pay for a pro account&lt;/li&gt;
	&lt;li&gt;Hackable (this could mean anything, but I know it when I see it. So not WordPress then.)&lt;/li&gt;
	&lt;li&gt;Export plain text out&lt;/li&gt;
	&lt;li&gt;Use my own domain name&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I have a sneaking suspicion what I might be thinking about is a private tumblr blog used as a datasource for &lt;a href="http://nanoc.stoneship.org/"&gt;Nanoc3&lt;/a&gt;. But that relies on me having the time to build that as I can&amp;#8217;t find anyone who might have written such a think. Maybe one day.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-02-11:/2010/02/11/djugl-february.html</id>
    <title type="html">DJUGL February</title>
    <published>2010-02-11T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/02/11/djugl-february.html"/>
    <content type="html">&lt;p&gt;The next Django User Group London is in two weeks time. You can register over on &lt;a href="http://londonpython.eventwax.com/djugl-february"&gt;Eventwax&lt;/a&gt;. So far we have &lt;a href="http://intranation.com"&gt;Brad&lt;/a&gt; talking with more speakers to be announced shortly. Hope to see a few people there.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-02-01:/2010/02/01/rise-house-team.html</id>
    <title type="html">The rise of the in-house team?</title>
    <published>2010-02-01T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/02/01/rise-house-team.html"/>
    <content type="html">&lt;p&gt;I was just thinking about the &lt;a href="http://www.dibiconference.com/"&gt;Design it Build it&lt;/a&gt; conference later in the year (full disclosure: I&amp;#8217;m speaking). Specifically the people speaking on the developer track. Between myself, Michael Brunton-Spall from The Guardian, David Singleton from Last.fm and Emma Persky from Gumtree four of the six speakers work on in-house teams. Not early stage start-ups, not large software/advertising companies, not as freelancers but in a reasonable sized company on a development team.&lt;/p&gt;
&lt;p&gt;My original background was working in agencies, and then a stint working for myself and I&amp;#8217;m constantly interested by the different facets of the web software industry. I think conferences or magazines aimed at your average interested web developer or designer play an interesting role in what people perceive as normal. If all you see are people who work as a freelancer you start to think that must be way cooler than whatever it is you&amp;#8217;re doing at the time. I remember attending the first @media event and being surprised at the small number of people from larger agencies. Everyone was from smaller boutique places, or Yahoo! or a freelancer. Now lots of people I see at events are involved in startups.&lt;/p&gt;
&lt;p&gt;Interestingly as well none of it is about a particular language or framework. Thinking about it as I type I think between the four of us we spend are day jobs mainly using different languages (java, python, php, perl). But I bet we all work in environments where we use other languages at least occasionally, or at the least the people around us do. Mixed environments are commonplace in companies that have been around a good while and run on software. They are far less common elsewhere with startups using whatever is cool (lets build a mobile search engine in Haskel anyone?) and small agencies often using whatever they built their first client website with (probably &lt;span class="caps"&gt;PHP&lt;/span&gt;).&lt;/p&gt;
&lt;p&gt;What I&amp;#8217;m really interested in though is the type of topics that are going to be talked about. Last.fm vs the Xbox, Scaling the Guardian, my rambling thoughts on a modern toolbox for developers beyond your average &lt;span class="caps"&gt;LAMP&lt;/span&gt; or .&lt;span class="caps"&gt;NET&lt;/span&gt; stack. This is the sort of think I&amp;#8217;m interested in. It&amp;#8217;s the sort of problems I like having. It&amp;#8217;s also, I think, the sort of stuff that doesn&amp;#8217;t get a showing a many mainstream conferences. I&amp;#8217;m hoping it&amp;#8217;s all going to be fairly practical too &amp;#8211; things that whatever role people have they can take away and apply.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-01-30:/2010/01/30/rabbitmq-support-cucumber-nagios.html</id>
    <title type="html">RabbitMQ support for Cucumber-nagios</title>
    <published>2010-01-30T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/01/30/rabbitmq-support-cucumber-nagios.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;ve been doing more operations related work of late and am starting to use &lt;a href="http://auxesis.github.com/cucumber-nagios/"&gt;Cucumber-nagios&lt;/a&gt; for various monitoring tasks. &lt;a href="http://www.nagios.org/"&gt;Nagios&lt;/a&gt; might not be the most attractive of web interfaces but it&amp;#8217;s so simple to get clients up and running and extend to do what you need. Cucumber however has a lovely, text based, user interface. And although I&amp;#8217;m mainly working with Python at the moment cucumber-nagios (written in Ruby) really is the easiest way I&amp;#8217;ve found of writing simple functional tests.&lt;/p&gt;
&lt;p&gt;Cucumber-nagios is the creation of &lt;a href="http://holmwood.id.au/~lindsay/"&gt;Lindsay Holmwood&lt;/a&gt; and after several brief conversations over Twitter I set about adding a feature I wanted for my own monitoring setup. Namely support for keeping an eye on RabbitMQ.&lt;/p&gt;
&lt;p&gt;At the moment the code is in a &lt;a href="http://github.com/garethr/cucumber-nagios"&gt;fork on GitHub&lt;/a&gt; but I&amp;#8217;m hoping that once any rough edges have been ironed out and a few people have kicked the tyres then it will make it&amp;#8217;s way into trunk. If you want to use this with an existing project straight away you can always drop the contents of &lt;a href="http://github.com/garethr/cucumber-nagios/blob/master/lib/generators/project/features/steps/amqp_steps.rb"&gt;amqp_steps.rb&lt;/a&gt; into your feature steps file after installing the &lt;a href="http://gems.rubyforge.org/gems/amqp"&gt;amqp gem&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I&amp;#8217;ve included a little documentation in the fork as well with a quick example:&lt;/p&gt;
&lt;pre&gt;Feature: github.com
  To make sure the rest of the system is in order
  All our message queues must not be backed up
  Scenario: test queue
    Given I have a AMQP server on rabbit.github.com
    And I want to check on the fork queue
    Then it should have less than 400 messages
    Then it should have at least 5 consumers
    Then it should have less than 50 messages per consumer&lt;/pre&gt;
&lt;p&gt;My main usecase was to keep an eye on a known queue size and number of consumers. I&amp;#8217;m sure I&amp;#8217;m missing some features at the moment so any feedback much appreciated.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-01-26:/2010/01/26/processing-large-files-sed-and-awk.html</id>
    <title type="html">Processing large files with sed and awk</title>
    <published>2010-01-26T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/01/26/processing-large-files-sed-and-awk.html"/>
    <content type="html">&lt;p&gt;I found myself using a couple of powerful but underused command line applications this week and felt like sharing.&lt;/p&gt;
&lt;p&gt;My problem involved a large text file with over three million lines and a script that processed the file line by line, in this case running a &lt;span class="caps"&gt;SQL&lt;/span&gt; query against a remote database.&lt;/p&gt;
&lt;p&gt;My script didn&amp;#8217;t try and process everything in one go, rather taking off large chunks and processing them in turn, then stopping and printing out the number of lines processed. This was mainly so I could keep an eye on it and make sure it wasn&amp;#8217;t having a detrimental affect on other systems. But once I&amp;#8217;d run the script once (and processed the first quarter of a million records or so) I wanted to run it again, except without the first batch of lines. For this I used sed. The following command creates a new file with the contents of the original file, minus the first 254263 lines.&lt;/p&gt;
&lt;pre&gt;sed '1,254263d' original.txt &amp;gt; new.txt&lt;/pre&gt;
&lt;p&gt;I could then run my script with the input from new.txt and not have to reprocess the deleted lines. My next problem came when the network connection between the box running the script and the database dropped out. The script printed out the contents of the last line successfully processed, so what I wanted was a new file with the all contents of the old file past the last line. The following awk command does just that, assuming the last line processed was f251f9ee0b39beb5b5c4675ed4802113.&lt;/p&gt;
&lt;pre&gt;awk '/^f251f9ee0b39beb5b5c4675ed4802113/{f=1;next}f' original.txt &amp;gt; new.txt&lt;/pre&gt;
&lt;p&gt;Now I could have made the script that did the work more complicated and ensure it dealt with these cases. But it would have involved much more code and the original scripts where only a handful of throw away code. For one off jobs like this a quick dive into the command line seemed more prudent.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2010-01-07:/2010/01/07/speaking-dibi.html</id>
    <title type="html">Speaking at DIBI</title>
    <published>2010-01-07T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2010/01/07/speaking-dibi.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;ll be heading back up to Newcastle in April to give a talk at what&amp;#8217;s shaping up to be a good looking conference to kick off the year with. &lt;a href="http://www.whatisdibi.com/"&gt;&lt;span class="caps"&gt;DIBI&lt;/span&gt;&lt;/a&gt; is trying to please everyone, with both front and backend focused streams.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Created for both sides of the web coin, &lt;span class="caps"&gt;DIBI&lt;/span&gt; brings together designers and developers for an unusual two-track web conference. World renowned speakers leading in their fields of work will talk about all things web. Taking place in Newcastle upon Tyne, (it&amp;#8217;s oop north) at The Sage Gateshead on the 28th April 2010, we&amp;#8217;re bringing both sides of the web world together with some awesome speakers.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I&amp;#8217;m not a big fan of making a point of dividing frontend and backend work. You nearly always end up with javascript dominated horribleness (because we only had a front end person available) or a so called content management system that means all sites have to look the same except for the colour palette. So I&amp;#8217;m hoping lots of cross over stuff happens and interesting conversations abound.&lt;/p&gt;
&lt;p&gt;Oh, and if you&amp;#8217;re wondering what I&amp;#8217;ll be speaking about it&amp;#8217;s probably going to be something about all the cool tools you could and should be using when building or looking after web applications. I&amp;#8217;ll probably be doing my best to convince people to look outside the comfort of the &lt;span class="caps"&gt;LAMP&lt;/span&gt; or C#/&lt;span class="caps"&gt;MSSQL&lt;/span&gt; stacks and realise the future for lots of web developers might just be more devops.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2009-11-28:/2009/11/28/dreque.html</id>
    <title type="html">Dreque</title>
    <published>2009-11-28T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2009/11/28/dreque.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;ve just found &lt;a href="http://github.com/samuel/dreque"&gt;Dreque&lt;/a&gt; from &lt;a href="http://samuelks.com/"&gt;Samuel Stauffer&lt;/a&gt; on GitHub. It&amp;#8217;s yet another take on the whole messaging things which is definitely seeing a lot of activity at the back end of this year. It&amp;#8217;s using &lt;a href="http://code.google.com/p/redis/"&gt;Redis&lt;/a&gt; on the backend and looks really rather nice:&lt;/p&gt;
&lt;p&gt;Submitting jobs:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;from dreque import Dreque
def some_job(argument):
    pass
dreque = Dreque("127.0.0.1")
dreque.enqueue("queue", some_job, argument="foo")&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Worker:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;from dreque import DrequeWorker
worker = DrequeWorker(["queue"], "127.0.0.1")
worker.work()&lt;/code&gt;&lt;/pre&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2009-11-05:/2009/11/05/djugl-december.html</id>
    <title type="html">DJUGL December</title>
    <published>2009-11-05T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2009/11/05/djugl-december.html"/>
    <content type="html">&lt;p&gt;As mentioned at the last event I&amp;#8217;ve taken over organising the Django User Group London event from Rob. Tickets are now available for the next event which is going to be on the 3rd of December at The Guardian offices in Kings Cross.&lt;/p&gt;
&lt;p&gt;You can sign up on &lt;a href="http://londonpython.eventwax.com/djugl-december"&gt;eventwax&lt;/a&gt;&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2009-11-01:/2009/11/01/erlang-screencasts.html</id>
    <title type="html">Erlang Screencasts</title>
    <published>2009-11-01T00:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2009/11/01/erlang-screencasts.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;ve been trying to learn Erlang for a while. What I actually mean is it&amp;#8217;s been on my list of &lt;em&gt;things to learn&lt;/em&gt; for months, along with all sorts of other incredibly interesting bits and pieces. I spend a little bit of time at home but the majority of my learning time is now spent commuting to London and back most days. Sometimes I&amp;#8217;m even going all the way to Swindon which gives me even longer to not learn Erlang.&lt;/p&gt;
&lt;p&gt;The main problem with learning something new on the train is space. Reading a book (or my new Kindle) or just using my laptop is fine. Trying to do both at once is nearly impossible (I&amp;#8217;ve tried). So I&amp;#8217;ve decided to give another approach a try, namely screencasts.&lt;/p&gt;
&lt;p&gt;I&amp;#8217;ve only done the first &lt;a href="http://www.pragprog.com/screencasts/v-kserl/erlang-in-practice"&gt;Erlang in Practice&lt;/a&gt; episode so far but I was hugely impressed with the content and general presentation. $5 as well doesn&amp;#8217;t seem bad at all I don&amp;#8217;t think. The episode was half an hour long, but took me a little longer, probably closer to 45 minutes, as I was playing along at home and typing the code examples as I went. I also got sidetracked with messing with my vim configuration at the same time but hey. This makes them perfect for my hour long commute. The full series is 8 episodes long and with luck I&amp;#8217;ll be able to work through them this week.&lt;/p&gt;
&lt;p&gt;So, good job &lt;a href="http://weblog.hypotheticalabs.com/"&gt;Kevin Smith&lt;/a&gt; and &lt;a href="http://www.pragprog.com"&gt;Pragmatic&lt;/a&gt; for a nice, accessible start to Erlang. All I need to do now is find something interesting to hack on in Erlang.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2009-10-24:/2009/10/24/django-committers.html</id>
    <title type="html">Django Committers</title>
    <published>2009-10-23T23:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2009/10/24/django-committers.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;ve been lurking on the django-developers mailing list for the last couple of weeks and that provided an excuse to play with the &lt;a href="http://blog.twitter.com/2009/09/soon-to-launch-lists.html"&gt;new Twitter Lists&lt;/a&gt; feature. So here&amp;#8217;s a &lt;a href="http://twitter.com/garethr/djangocommitters"&gt;list of djangocommitters on twitter&lt;/a&gt;. If I missed someone do let me know. Their is a chance you won&amp;#8217;t be able to see this if you&amp;#8217;re not on the beta yet I think, sorry!&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2009-10-18:/2009/10/18/problems-installing-hadoop-and-dumbo-ubuntu.html</id>
    <title type="html">Problems Installing Hadoop 0.20 and Dumbo 0.21 on Ubuntu</title>
    <published>2009-10-17T23:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2009/10/18/problems-installing-hadoop-and-dumbo-ubuntu.html"/>
    <content type="html">&lt;p&gt;The Hadoop wiki has a great introduction to &lt;a href="http://wiki.apache.org/hadoop/Running_Hadoop_On_Ubuntu_Linux_(Single-Node_Cluster)"&gt;installing this piece of software&lt;/a&gt;, which I wanted to do to have a play with &lt;a href="http://klbostee.github.com/dumbo/"&gt;Dumbo&lt;/a&gt;. The Dumbo docs also have a good &lt;a href="http://wiki.github.com/klbostee/dumbo/building-and-installing"&gt;getting started&lt;/a&gt; section which includes a few patches than need to be applied.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Dumbo can be considered to be a convenient Python &lt;span class="caps"&gt;API&lt;/span&gt; for writing MapReduce programs&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Unfortunately it&amp;#8217;s not quite that simple, at least on Ubuntu Jaunty. Hadoop now uses Java6, but if you just follow the instructions on the wikis you&amp;#8217;ll hit a problem when you run &amp;#8216;&amp;#8217;ant package&amp;#8217;&amp;#8216;, namely that a third party application (&lt;a href="http://forrest.apache.org/"&gt;Apache Forrest&lt;/a&gt;) requires Java 1.5. Once you fix that, the build script will complain again that you need to install Forrest. Here&amp;#8217;s what I did to get everything working:&lt;/p&gt;
&lt;pre&gt;sudo apt-get install ant sun-java5-jdk&lt;/pre&gt;
&lt;pre&gt;su - hadoop
wget http://mirrors.dedipower.com/ftp.apache.org/forrest/apache-forrest-0.8.tar.gz
tar xzf apache-forrest-0.8.tar.gz
cd /usr/local/hadoop
patch -p0 &amp;lt; /path/to/HADOOP-1722.patch
patch -p0 &amp;lt; /path/to/HADOOP-5450.patch
patch -p0 &amp;lt; /path/to/MAPREDUCE-764.patch
ant package -Djava5.home=/usr/lib/jvm/java-1.5.0-sun -Dforrest.home=/home/hadoop/apache-forrest-0.8/&lt;/pre&gt;
&lt;p&gt;With all that out of the way you should be able to run the &lt;a href="http://dumbotics.com/2009/05/31/dumbo-on-clouderas-distribution/"&gt;simple examples&lt;/a&gt; found on the rather excellent &lt;a href="http://dumbotics.com"&gt;dumbotics&lt;/a&gt; blog. If you&amp;#8217;re using the Cloudera distribution, or when the Hadoop 0.21 gets a release, these problems will disappear but in the meantime hopefully this saves someone else a bit of head scratching.&lt;/p&gt;</content>
  </entry>
  <entry>
    <id>tag:morethanseven.net,2009-09-21:/2009/09/21/learnings-september.html</id>
    <title type="html">Learnings from September</title>
    <published>2009-09-20T23:00:00Z</published>
    <updated>2010-03-06T16:11:35Z</updated>
    <link rel="alternate" href="http://morethanseven.net/2009/09/21/learnings-september.html"/>
    <content type="html">&lt;p&gt;I&amp;#8217;m keep meaning to get around to writing about why I think the future of web developers is operations but in lieu of a proper post here&amp;#8217;s a list of things I&amp;#8217;ve been spending my work life getting to know this month:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;&lt;a href="http://reductivelabs.com/products/puppet"&gt;Puppet&lt;/a&gt; &amp;#8211; It&amp;#8217;s brilliant. Define (with a Ruby &lt;span class="caps"&gt;DSL&lt;/span&gt; of course) what software and services you want running on all your machines, install a daemon on each of them, and hey presto central configuration management.&lt;/li&gt;
	&lt;li&gt;&lt;a href="http://www.vmware.com/products/vsphere/"&gt;VMWare vsphere&lt;/a&gt; &amp;#8211; puppet makes more sense the more boxes you have. With vsphere I can have as many boxes as I want (nearly). Command line scripts and an actually very nice windows gui for settings up virtual machines is all pretty nice, especially running on some meaty hardware.&lt;/li&gt;
	&lt;li&gt;&lt;a href="http://nagios.org/"&gt;Nagios&lt;/a&gt; &amp;#8211; With lots of boxes comes lots of responsibility (or something). Nagios might look a bit ugly, and bug me with it&amp;#8217;s needless frames based admin, but I can see what people see in it. Which frankly is the ability to monitor everything everywhere for any change what-so-ever.&lt;/li&gt;
	&lt;li&gt;&lt;a href="http://lucene.apache.org/solr/"&gt;Solr&lt;/a&gt; &amp;#8211; I&amp;#8217;m now also pretty well versed in using Solr. I&amp;#8217;ve used it in the past, but always behind a Ruby or Python library. Now I know my way around all the &lt;span class="caps"&gt;XML&lt;/span&gt; based configuration inards. Heck, I&amp;#8217;m even running a nighly release from a couple of days ago in a production environment because I wanted a cool new feature. A special mention to the Solr community on the mailing list, twitter and irc for being great when I had questions.&lt;/li&gt;
	&lt;li&gt;Solaris &amp;#8211; I nearly forgot, I spend more time than I care to remember working out how to use Open Solaris (conclusion: OK, but not Debian) and eventually Solaris 10 (conclusion: hope I don&amp;#8217;t have to do that again). My installation notes read like some hideous hack but everything works fine in production and it&amp;#8217;s scarily repeatable so I&amp;#8217;ll live with it for now.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I do wonder if it&amp;#8217;s just me that&amp;#8217;s drawn to knowing how everything in the full web stack works. But personally I can&amp;#8217;t just write code if I don&amp;#8217;t understand how to deploy it or what it&amp;#8217;s running on. Front end types know this all too well. Being a master of &lt;span class="caps"&gt;CSS&lt;/span&gt;, &lt;span class="caps"&gt;HTML&lt;/span&gt; and Javascript simply isn&amp;#8217;t enough. You need to understand the browser to get anything done. I&amp;#8217;m not sure it&amp;#8217;s the same for all backend inclined folk; how many &lt;span class="caps"&gt;PHP&lt;/span&gt; programmers really understand Apache and a few other useful bits of web tech?&lt;/p&gt;</content>
  </entry>
</feed>
