'Runs this ``Job``.  If ``save`` is ``True`` the dates (``last_run`` and ``next_run``)
are updated.  If ``save`` is ``False`` the job simply gets run and nothing changes.
A ``Log`` will be created if there is any output from either stdout or stderr.'

def run(self, save=True):

    run_date = datetime.now()
    self.is_running = True
    self.save()
    (stdout_str, stderr_str) = ('', '')
    try:
        if self.shell_command:
            (stdout_str, stderr_str) = self.run_shell_command()
        else:
            (stdout_str, stderr_str) = self.run_management_command()
    finally:
        self = self.__class__.objects.get(id=self.id)
        self.last_run_successful = (not bool(stderr_str))
        self.is_running = False
        self.save()
    if save:
        self.last_run = run_date
        self.next_run = self.rrule.after(run_date)
        self.save()
    end_date = datetime.now()
    log = Log.objects.create(job=self, run_date=run_date, end_date=end_date, stdout=stdout_str, stderr=stderr_str, success=self.last_run_successful)
