Error alerts

Closes #46 

@rcrichton quite a big merge, if you could please review? I'm sure there are lots of things we can do to make this better, but I think it's good enough for a first version.

Just some notes:
* I've implement the percentage-based `failureRate`. So the field specifies the percentage of transactions that have to match the particular status during the last hour in order to trigger the alert.
* I've added a field `maxAlerts`. We can therefore specify what the max number of alerts are. Current options are _no max_ - meaning the user will get all alerts, or _1 per hour_ and _1 per day_.
* I've made some changes to the server startup/stop code (esp. stop). Even though it's not really related to this issue, it is however required for it (it's good to stop agenda properly) so seems okay to me to bundle the change here.
* The default polling period for the agenda task is 1 minute.
Ok, that seems fine to me.