nathanmac / laravel-queue-softlayer
SoftLayer 消息驱动程序,用于 Laravel 队列
v1.1
2014-11-20 16:00 UTC
Requires
- php: >=5.4.0
- illuminate/queue: 4.2.*
- illuminate/support: 4.2.*
- nathanmac/softlayer-message-queue-php: 1.*
Requires (Dev)
- mockery/mockery: ~0.9
- phpunit/phpunit: ~4.0
This package is not auto-updated.
Last update: 2024-09-24 01:46:14 UTC
README
安装
在 composer.json 中要求此包,并运行 composer update
"nathanmac/laravel-queue-softlayer": "1.*"
或者运行
composer require "nathanmac/laravel-queue-softlayer"
在 composer update 完成后,您需要将 ServiceProvider 添加到 app.php 中的 providers
数组中
'Nathanmac\LaravelQueueSoftLayer\LaravelQueueSoftLayerServiceProvider',
现在您可以在 queue.php 中配置您的连接
return [
'default' => 'softlayer',
'connections' => [
'softlayer' => [
'driver' => 'softlayer',
'account' => '', // SoftLayer Queue Account
'username' => '', // SoftLayer Username
'token' => '', // SoftLayer Password
'queue' => '', // name of the default queue
// Optional configuration settings for SoftLayer
'endpoint' => 'dal05',
'private' => true
],
],
];
用法
完成配置后,您可以使用 Laravel 队列 API。如果您使用了其他队列驱动程序,您不需要更改其他任何内容。如果您不知道如何使用队列 API,请参阅官方 Laravel 文档:https://laravel.net.cn/docs/queues