fusonic/framework-bundle

Opinionated collection of classes and functionalities used throughout Fusonic's Symfony projects

Installs: 118

Dependents: 0

Suggesters: 0

Security: 0

Stars: 1

Watchers: 1

Forks: 0

Open Issues: 0

Type:symfony-bundle

0.1.0 2025-07-18 11:11 UTC

This package is auto-updated.

Last update: 2025-07-18 11:14:56 UTC


README

License Latest Version Total Downloads php 8.2+

About

This Symfony bundle provides an opinionated collection of classes and functionalities used throughout Fusonic's Symfony projects, designed to simplify and standardize common development patterns.

Key features include:

  • Doctrine Entity Identifier Management: Integration of symfony/uid alongside fusonic/ddd-extensions to allow Doctrine entities to use UUIDs in the form of typed classes as primary identifiers.
  • Message Bus Configurations: Simplified handling of symfony/messenger message buses using typed classes, allowing for easier message dispatching and clean separation of commands, queries, and events.

Install

Use Composer to install the bundle.

composer require fusonic/framework-bundle

Requirements:

  • PHP 8.2+
  • Symfony 6.4+

In case Symfony did not add the bundle to the bundle configuration, add the following (by default, located in config/bundles.php):

<?php

return [
    // ...
    Fusonic\FrameworkBundle\FusonicFrameworkBundle::class => ['all' => true],
];

Configuration

The bundle assumes that the symfony/messenger bus services IDs for the command, event, and query buses are as follows:

  • command.bus
  • event.bus
  • query.bus

If this is not the case, you can freely configure the service IDs by creating a new config/packages/fusonic_framework.php file (or an equivalent YAML file) as follows:

<?php

use Symfony\Config\FusonicFrameworkConfig;

return static function (FusonicFrameworkConfig $frameworkConfig): void {
    $frameworkConfig
        ->messenger()
            ->bus()
                ->commandBus('command.bus.with.other.name');
                ->eventBus('event.bus.with.other.name')
                ->queryBus('query.bus.with.other.name');
};

Contributing

This is a subtree split of the fusonic/php-extensions repository. Please create your pull requests there.