定制 williamrijksen/symfony-messenger-azure 二次开发

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

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

williamrijksen/symfony-messenger-azure

Composer 安装命令:

composer require williamrijksen/symfony-messenger-azure

包简介

Azure adapter for symfony/messenger component

README 文档

README

Build Status

This is an experimental Receiver/Sender on Azure for the symfony/messenger component for topic and subscribers.

Quick start

First of all: This uses topics / subscriptions like described here. Make sure you have a connection-string ready.

For now we're exposing a bundle which is pre-configuring the Messenger component with receivers and senders.

composer require symfony/messenger williamrijksen/symfony-messenger-azure

Add the bundle new WilliamRijksen\AzureMessengerAdapter\Bundle\AzureMessengerAdapterBundle().

Add the following configuration:

azure_messenger_adapter:
    azure:
        connectionString: 'Endpoint=<your token>'
        subscriptionName: 'name of subscription' #topic will be automatically created by this bundle
    messages:
        'App\Message\Foo': 'foo_topic' #topic will be automatically created by this bundle

Add a message handler:

<?php

namespace App\MessageHandler;

use App\Message\Foo;

final class FooHandler
{
    public function __invoke(Foo $message)
    {
    }
}

Tag it:

services:
  App\MessageHandler\FooHandler:
      tags:
          - { name: messenger.message_handler }

You're done!

Launch bin/console messenger:consume-messages azure_messenger.receiver.foo_queue and dispatch messages from the bus:

<?php
$bus->dispatch(new Foo());

Configuration reference

azure_messenger_adapter:
    azure:
        connectionString: 'Endpoint=<your token>'
        subscriptionName: 'name of subscription'
    messages:
        'App\Message\Foo': 'foo_topic'

Links

统计信息

  • 总下载量: 375
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 7
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 6
  • Watchers: 1
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-12-11

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固