Download the PHP package zenaton/zenaton-php without Composer

On this page you can find all versions of the php package zenaton/zenaton-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package zenaton-php

⚠️ This repository is abandoned.


Easy Asynchronous Jobs Manager for Developers
Explore the docs »
Website · Examples in PHP · Tutorial in PHP

Packagist CircleCI

Zenaton library for PHP

Zenaton helps developers to easily run, monitor and orchestrate background jobs on your workers without managing a queuing system. In addition to this, a monitoring dashboard shows you in real-time tasks executions and helps you to handle errors.

The Zenaton library for PHP lets you code and launch tasks using Zenaton platform, as well as write workflows as code. You can sign up for an account on Zenaton and go through the tutorial in PHP.

PHP Documentation

You can find all details on Zenaton's website.

Table of contents - [Getting started](#getting-started) - [Installation](#installation) - [Install the Zenaton Agent](#install-the-zenaton-agent) - [Install the library](#install-the-library) - [Framework integration](#framework-integration) - [Quick start](#quick-start) - [Client Initialization](#client-initialization) - [Executing a background job](#executing-a-background-job) - [Orchestrating background jobs](#orchestrating-background-jobs) - [Using workflows](#using-workflows) - [Getting help](#getting-help)

Getting started

Installation

Install the Zenaton Agent

To install the Zenaton agent, run the following command:

Then, you need your agent to listen to your application. To do this, you need your Application ID and API Token. You can find both on your Zenaton account.

Install the library

To add the latest version of the library to your project, run the following command:

Framework integration

If you are using Laravel or Symfony, please refer to our dedicated documentation to get started:

Quick start

Client Initialization

To start, you need to initialize the client. To do this, you need your Application ID and API Token. You can find both on your Zenaton account.

Then, initialize your Zenaton client:

Executing a background job

A background job in Zenaton is a class implementing the Zenaton\Interfaces\TaskInterface interface.

Let's start by implementing a first task printing something, and returning a value:

Now, when you want to run this task as a background job, you need to do the following:

That's all you need to get started. With this, you can run many background jobs. However, the real power of Zenaton is to be able to orchestrate these jobs. The next section will introduce you to job orchestration.

Orchestrating background jobs

Job orchestration is what allows you to write complex business workflows in a simple way. You can execute jobs sequentially, in parallel, conditionally based on the result of a previous job, and you can even use loops to repeat some tasks.

We wrote about some use-cases of job orchestration, you can take a look at these articles to see how people use job orchestration.

Using workflows

A workflow in Zenaton is a class implementing the Zenaton\Interfaces\WorkflowInterface interface.

We will implement a very simple workflow:

First, it will execute the HelloWorld task. The result of the first task will be used to make a condition using an if statement. When the returned value will be greater than 0, we will execute a second task named FinalTask. Otherwise, we won't do anything else.

One important thing to remember is that your workflow implementation must be idempotent. You can read more about that in our documentation.

The implementation looks like this:

Now that your workflow is implemented, you can execute it by calling the dispatch method:

If you really want to run this example, you will need to implement the FinalTask task.

There are many more features usable in workflows in order to get the orchestration done right. You can learn more in our documentation.

Getting help

Need help? Feel free to contact us by chat on Zenaton.

Found a bug? You can open a GitHub issue.


All versions of zenaton-php with dependencies

PHP Build Version
Package Version
Requires php Version >=5.6.0
ext-json Version *
cakephp/chronos Version ^1.1
jeremeamia/superclosure Version ^2.2
nategood/httpful Version ^0.2
ramsey/uuid Version ^3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package zenaton/zenaton-php contains the following files

Loading the files please wait ....