适用于Laravel的腾讯云CMQ队列适配器

This is a queue adapter for the QCloud CMQ

Installation

composer require larva/laravel-tencent-cloud-cmq-queue

for Laravel

This service provider must be registered.

// config/app.php

'providers' => [
    '...',
    Larva\TencentCloud\Cmq\Queue\CMQServiceProvider::class,
];

edit the config file: config/queue.php

add config

        'cmq' => [
            'driver' => 'cmq',
            'secret_Id' => env('CMQ_SECRET_ID', 'your-secret_Id'),
            'secret_Key' => env('CMQ_SECRET_KEY', 'your-secret_Key'),
            'endpoint' => 'https://cmq-queue-bj.api.qcloud.com',
            'queue' => 'default'
        ],

change default to cmq

    'default' => 'cmq'

Use

see Laravel wiki

发布了57 篇原创文章 · 获赞 0 · 访问量 2194

猜你喜欢

转载自blog.csdn.net/zhidc/article/details/105261623
今日推荐