protected function startScheduler()
    {
        $this->now = new \DateTime('now', new \DateTimeZone('UTC'));

        $periodStart = clone $this->now;
        $periodStart->modify('-'.$this->interval.' minutes');

        $scheduler = new Scheduler();
        $scheduler->setStatus(Scheduler::STATUS_RUNNING);
        $scheduler->setExecutionStart($this->now);
        $scheduler->setPeriodStart($periodStart);
        $scheduler->setPeriodEnd($this->now);
        $scheduler->setPeriodInterval($this->interval);

        $this->em->persist($scheduler);
        $this->em->flush();

        return $scheduler;
    }