Hello
I have some problem with cronjobs
I created a Cron class inside my lib
Apps/myApp/lib/BackgroundJob/MyCronClass which extends ( OC\BackgroundJob\TimedJob) and set this in my info.xml like below
Grep CRON /var/log/syslog tell me that cron is running under root and is ok
For test I put mkdr(’data/testfolder’) at the start of cron.php and every one Minutes it create a testfolder in my data folder
But content of Run method in MyCronClass not executed !!!
here is my class
namespace OCA\MyApp\BackgroundJob;
use OC\BackgroundJob\TimedJob;
use OCA\MyTableMapper;
class MyCronClass extends TimedJob
{
private $mapper;
public function __construct(MyTableMapper $MyTableMapper)
{
$this->mapper = $MyTableMapper;
parent::setInterval(1);
}
protected function run($args)
{
$this->mapper->createSomeRowInTable('test');
}
}