code: function onDeployError(deploy) {
      if (typeof self.FLEETS[deploy.id] === 'undefined') return; //nothing else to do.
      var fleet = self.FLEETS[deploy.id];
      fleet.failed++;
      fleet.failed_total++;
      var allowedError = self.getFleetError(deploy.repo);
      if (allowedError.indexOf('%') === -1) { // we have a number.
        allowedError = parseInt(allowedError, 10);
      } else {  // we have a percentage.
        var perc = parseInt(allowedError.replace('%', ''), 10);
        allowedError = Math.floor(perc / 100 * fleet.total);
      }
      // IF we have a max error rate, we stop the deploy.
      if (fleet.failed_total >= allowedError) {
        self.emit('deploy.error', deploy);
        self.log('fatal', 'Error threshold ' + fleet.failed_total + ' reached for deploy ' + deploy.id + ' on ' + deploy.repo);
        clearTimeout(fleet._timeout);
        delete self.FLEETS[deploy.id];
        return;
      }
      // IF we're still acceptable, we run next.
      createFleet(deploy);
    }
docs: /* Called when a deploy contained errors.