Skip to content

Commit

Permalink
added LockingTaskHandlerInterface to handler-class
Browse files Browse the repository at this point in the history
  • Loading branch information
wachterjohannes committed May 15, 2017
1 parent 676c026 commit fc79bc4
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion PageTree/PageTreeRouteUpdateHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@
use Sulu\Bundle\ContentBundle\Document\BasePageDocument;
use Sulu\Component\DocumentManager\DocumentManagerInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Task\Lock\LockingTaskHandlerInterface;

/**
* Task-Handler to update page-tree-routes.
*/
class PageTreeRouteUpdateHandler implements AutomationTaskHandlerInterface
class PageTreeRouteUpdateHandler implements AutomationTaskHandlerInterface, LockingTaskHandlerInterface
{
/**
* @var PageTreeUpdaterInterface
Expand Down Expand Up @@ -79,4 +80,12 @@ public function handle($workload)

$this->documentManager->flush();
}

/**
* {@inheritdoc}
*/
public function getLockKey($workload)
{
return self::class;
}
}

0 comments on commit fc79bc4

Please sign in to comment.