chrishemmings / gps-messenger-bundle

The bundle provides a simple implementation of Google Pub/Sub transport for Symfony Messenger.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Google Pub/Sub transport implementation for Symfony Messenger

This bundle provides a simple implementation of Google Pub/Sub transport for Symfony Messenger.

GPS Messenger Bundle CI

The bundle requires only symfony/messenger, google/cloud-pubsub and symfony/options-resolver packages. In contrast with Enqueue GPS transport, it doesn't require Enqueue and some bridge. It supports ordering messages with OrderingKeyStamp and it's not outdated.

Installation

Step 1: Install the Bundle

From within container execute the following command to download the latest version of the bundle:

$ composer require petitpress/gps-messenger-bundle --no-scripts

Step 2: Configure Symfony Messenger

# config/packages/messenger.yaml

framework:
    messenger:
        transports:
            gps_messages:
                dsn: 'gps://'
                options:
                    topic_name: 'topic_name'
                    subscription_name: 'subscription_name'
                    key_file_path: 'path/to/key.json'
                    project_id: 'project_id'
                    max_messages_pull: 10

Step 3: Use available stamps if needed

  • OrderingKeyStamp: use for keeping messages of the same context in order. For more information, read an official documentation.

About

The bundle provides a simple implementation of Google Pub/Sub transport for Symfony Messenger.

License:MIT License


Languages

Language:PHP 100.0%