Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Laravel queue package #137

Merged
merged 5 commits into from
Jul 20, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ Features:
* [Null](docs/transport/null.md).
* [Symfony bundle](https://github.com/php-enqueue/enqueue-dev/blob/master/docs/bundle/quick_tour.md)
* [Magento1 extension](https://github.com/php-enqueue/enqueue-dev/blob/master/docs/magento/quick_tour.md)
* [Laravel extension](https://github.com/php-enqueue/enqueue-dev/blob/master/docs/laravel/quick_tour.md)
* [Message bus](http://www.enterpriseintegrationpatterns.com/patterns/messaging/MessageBus.html) support.
* [RPC over MQ](https://www.rabbitmq.com/tutorials/tutorial-one-php.html) support.
* Temporary queues support.
Expand Down
2 changes: 2 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@
- [Functional testing](bundle/functional_testing.md)
* Async event dispatcher (Symfony)
- [Quick tour](async_event_dispatcher/quick_tour.md)
* Laravel
- [Quick tour](laravel/quick_tour.md)
* Magento
- [Quick tour](magento/quick_tour.md)
- [Cli commands](magento/cli_commands.md)
Expand Down
53 changes: 53 additions & 0 deletions docs/laravel/quick_tour.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Laravel Queue. Quick tour.

The [LaravelQueue](https://github.com/php-enqueue/laravel-queue) allows to use [queue-interop](https://github.com/queue-interop/queue-interop) compatible transports as [Laravel Queue](https://laravel.com/docs/5.4/queues).

## Install

You have to install `enqueue/laravel-queue` packages and one of the [supported transports](https://github.com/php-enqueue/enqueue-dev/tree/master/docs/transport).

```bash
$ composer require enqueue/larvel-queue enqueue/fs
```

## Register service provider

```php
<?php

// config/app.php

return [
'providers' => [
Enqueue\LaravelQueue\EnqueueServiceProvider::class,
],
];
```

## Configure

First, you have to configure a transport layer and set one to be default.

```php
<?php

// config/queue.php

return [
'connections' => [
'interop' => [
'driver' => 'interop',
'connection_factory_class' => \Enqueue\Fs\FsConnectionFactory::class,

// the factory specific options
'dsn' => 'file://'.realpath(__DIR__.'/../storage').'/enqueue',
],
],
];
```

## Usage

Same as standard [Laravel Queues](https://laravel.com/docs/5.4/queues)

[back to index](../index.md)