Background Jobs Manager On Steroids

Zenaton handles all of the complexity to run, monitor and orchestrate async jobs.

Get started now
I accept the terms of service

Need a quote? Please contact us

An Easy and Reliable Way to Manage Async Jobs

Save time and build better software.

How it works

Stop maintaining queueing systems

Focus on features instead of infrastructure. Zenaton provides a reliable queueing infrastructure that we host and deploy for you.

Spend less time troubleshooting

Zenaton manages all of the backend infrastructure so you don't have to worry about the network losing packets, failing disks or virtual machines terminating unexpectedly.

Monitor every execution

Our agent launches, monitors and logs every back-end execution and alerts you if something goes wrong.

Optimize Server Usage

Process jobs concurrently on your workers — even for mono-threaded languages.

Infinitely Scalable

It's easy to scale horizontally by adding more servers according to your needs.

Make your devops life easier

Zenaton dashboards give you a complete overview of your infrastructure where jobs are executed.

Orchestrate Async Jobs into World-Class Processes

Whatever the size of your technical team, Zenaton powers you businesswith the ability to deliver - even sophisticated - business processes,long-running marketing scenario or data pipelines.

Learn More

Everything as code

Zenaton lets you code asynchronous workflows as if they were run locally, but execute them in a distributed, scalable, durable and resilient way.

Moderation Workflow

This is typical of a moderation workflow where an external moderator should moderate an item:

  • an article is sent to a moderator
  • then we wait for the moderator's response
  • after 24h without response, we send a 1st reminder
  • after 24h without response, we send a 2nd reminder
  • after 24h without response, we send a 3rd reminder
  • if we don't have an answer or if the response is negative, we send a rejection notification

<?php

use Zenaton\Interfaces\WorkflowInterface;
use Zenaton\Traits\Zenatonable;
use Zenaton\Tasks\Wait;

class ModerationWorkflow implements WorkflowInterface
{
    use Zenatonable;

    public function __construct($article)
    {
        $this->article = $article;
    }

    public function handle()
    {
        $count = 0;
        do {
            (new SendArticleToModerator($this->article, $count))->execute();

            $event = (new Wait('ModerationEvent'))->hours(24)->execute();

            $count++;
        } while (! $event && $count < 4)

        if (! $event || ! $event->validated) {
            (new SendRejectionNotification($this->article))->execute();
        }
    }

    public function getId()
    {
        return $this->article->id;
    }
}

Welcome Process

This workflow illustrates how easy is to send a sequence of emails for new users:

  • A 1st email is sent to the user
  • Then we wait for 24h
  • A 2nd email is sent to the user
  • Then we wait for 36h
  • A 3rd email is sent to the user
  • Then we wait for 48h
  • A 4th email is sent to the user

<?php

use Zenaton\Interfaces\WorkflowInterface;
use Zenaton\Traits\Zenatonable;
use Zenaton\Tasks\Wait;

class WelcomeWorkflow implements WorkflowInterface
{
    use Zenatonable;

    public function __construct($user)
    {
        $this->user = $user;
    }

    public function handle()
    {
        (new SendWelcomeEmail1($this->user))->execute();

        (new Wait())->hours(24)->execute();

        (new SendWelcomeEmail2($this->user))->execute();

        (new Wait())->hours(36)->execute();

        (new SendWelcomeEmail3($this->user))->execute();

        (new Wait())->hours(48)->execute();

        (new SendWelcomeEmail4($this->user))->execute();
    }

    public function getId()
    {
        return $this->user->id;
    }
}

Shopping Cart Abandonment Workflow

Reducing shopping cart abandonment is an easy way to improve your conversion rate in ecommerce.

With Zenaton, a few lines of code is all you need. Note: a 'ShoppingCartEvent' is sent to this workflow each time something is added to the shopping cart. If the shopping cart is not purchased, an email is sent after 20 minutes of inactivity.

<?php

use Zenaton\Interfaces\WorkflowInterface;
use Zenaton\Traits\Zenatonable;
use Zenaton\Tasks\Wait;

class AbandonedShoppingCartWorkflow implements WorkflowInterface
{
    use Zenatonable;

    public function __construct($shoppingCart)
    {
        $this->shoppingCart = $shoppingCart;
    }

    public function handle()
    {
        do {
            $event = (new Wait('ShoppingCartEvent'))->minutes(20)->execute();
        } while ($event && $event->type !== 'purchased')

        if (! $event) {
            (new SendAbandonedShoppingCartEmail($this->shoppingCart))->execute();
        }
    }

    public function getId()
    {
        return $this->shoppingCart->id;
    }
}

Want to give it a try?

Start delivering new features and new processes faster