#Installation Install the Clockwork library via Composer.
$ composer require kolesa-team/phalcon-clockwork
Set events manager to service(di)
$di->set('eventsManager', function () {
$manager = new Phalcon\Events\Manager();
return $manager;
}, true);
Set events manager to Application
$eventsManager = $di->get('eventsManager');
$application = new Phalcon\Mvc\Application($di);
$application->setEventsManager($eventsManager)
Init clockwork
$clockwork = new ClockworkServices();
$clockwork->setEventsManager($di->get('eventsManager'));
$clockwork->initialize();