定制 tradecoverexchange/google-cloud-tasks-laravel 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

tradecoverexchange/google-cloud-tasks-laravel

Composer 安装命令:

composer require tradecoverexchange/google-cloud-tasks-laravel

包简介

A Laravel Queue driver to interact with Google Cloud Tasks

README 文档

README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

A Laravel Queue driver to interact with Google Cloud Tasks.

Installation

Requires Laravel 9 and PHP 8.1 as a minimum.

You can install the package via composer:

composer require tradecoverexchange/google-cloud-tasks-laravel

You can publish an overriding queue config file with:

php artisan vendor:publish --provider="TradeCoverExchange\GoogleCloudTaskLaravel\CloudTaskServiceProvider" --tag cloud-task-config --force

Or you can manually add the two following connections to your own queues.php config file:

return [
    'connections' => [
        'app_engine_tasks' => [
            'driver' => 'google_app_engine_cloud_tasks',
            'queue' => env('GOOGLE_CLOUD_TASKS_QUEUE', 'default'),
            'project_id' => env('GOOGLE_CLOUD_TASKS_PROJECT_ID', ''),
            'location' => env('GOOGLE_CLOUD_TASKS_LOCATION_ID', ''),
            'options' => [
                'credentials' => 'path/to/your/keyfile',
                'transport' => 'rest',
            ],
        ],

        'http_cloud_tasks' => [
            'driver' => 'google_http_cloud_tasks',
            'queue' => env('GOOGLE_CLOUD_TASKS_QUEUE', 'default'),
            'project_id' => env('GOOGLE_CLOUD_TASKS_PROJECT_ID', ''),
            'location' => env('GOOGLE_CLOUD_TASKS_LOCATION_ID', ''),
            'authentication' => [
                'token_type' => 'oidc',
                'service_account' => env('GOOGLE_CLOUD_TASKS_SERVICE_ACCOUNT', ''),
            ],
            'options' => [
                'credentials' => 'path/to/your/keyfile',
                'transport' => 'rest',
            ],
        ],
    ],
];

Usage

Usage of the package should primarily be done via the Laravel Queue system.

Missing Features

There is no ability to configure the worker options in the same way as a typical queue connection in Laravel.

For Http Tasks only the OIDC token type has been implemented for protecting the controller from fraudulent requests. We don't use OAuth ourselves but would be happy to include if someone makes a PR for it or knows how that mechanism should work compared to OIDC.

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

About Us

Trade Cover Exchange

Trade Cover Exchange is a platform for insuring your trade with other companies, protecting you from instabilities in the supply chain.

We proudly use the Google Cloud platform for our service and hope to share more of our work with the developer community in the future.

Security

If you discover any security related issues, please email peter@tradecoverexchange.com instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 7.09k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 2
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-08-18

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固