Download the PHP package t3n/jobqueue-log without Composer

On this page you can find all versions of the php package t3n/jobqueue-log. 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 jobqueue-log

CircleCI Latest Stable Version Total Downloads

t3n.JobQueue.Log

A sidecar package for t3n.JobQueue.RabbitMQ. This package will log infos about submitted, failed and finished jobs to a RabbitMQ backend. This package could also be used to simply log some custom messages.

Setup

To use RabbitMQ as a backend for a JobQueue you need a running RabbitMQ Service. You can use our docker image which also includes the management console t3n/rabbitmq

Install the package using composer:

Configuration

For a basic setup of RabbitMQ Queues check t3n.JobQueue.RabbitMQ. This section will only cover the additional configuration.

There are some preconfigured queues:

Adjust those queues to fit your needs. You probably want to adjust the routing key as well as the preset / exchange configuration. Those queue names are used internally, so make sure you got those covered! We won't declare them as they only act as a producer. There is no need to declare or persist them for now.

Now add a consumer queue like this:

This queue uses a TransientRabbitQueue. This is important as we override the default queue options to make sure it has a unique name so you several consumer can connect and all messages are forwarded to each consumer. The queue will also only exist as long as a consumer is connected (realised with the exclusive flag). This queue now would receive all logs with all severities. If you only need warnings adjust the routing key to your needs or configure another consumer queue.

We wont log anything by default but is able to log logs for submitted, failed and finished jobs. You can enable logging in your Settings.yaml:

Usage

After you configured your producer and consumer queues there is a flow command to output all logs:

The severity flag controls whether to log only failed Jobs (warning), submitted jobs (info) or finished jobs (success). By default all logs (*) are outputted. Setting verbose to true will also display some more meta information.

Send generic messages

This package is made to have a live overview of your jobqueues. But you can also use it to send some generic logs. Therefore we added the severity message.

Sending a message to all consumers:

The queue name, routing keys etc. can be customized to fit your needs!


All versions of jobqueue-log with dependencies

PHP Build Version
Package Version
Requires flowpack/jobqueue-common Version ^3.0.0
ext-json Version *
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 t3n/jobqueue-log contains the following files

Loading the files please wait ....