PHPackages                             solidframe/symfony - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. solidframe/symfony

ActiveSymfony-bundle[Framework](/categories/framework)

solidframe/symfony
==================

Symfony bridge for SolidFrame architectural packages

v0.1.0(1mo ago)05MITPHPPHP ^8.2

Since Apr 13Pushed 1mo agoCompare

[ Source](https://github.com/solidframe/symfony)[ Packagist](https://packagist.org/packages/solidframe/symfony)[ RSS](/packages/solidframe-symfony/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (8)Versions (2)Used By (0)

SolidFrame Symfony
==================

[](#solidframe-symfony)

Symfony bridge for SolidFrame architectural packages.

Bundle, compiler passes, console generators, DBAL stores, and modular monolith support — all wired into Symfony.

Installation
------------

[](#installation)

```
composer require solidframe/symfony
```

Register the bundle:

```
// config/bundles.php
return [
    // ...
    SolidFrame\Symfony\SolidFrameBundle::class => ['all' => true],
];
```

Features at a Glance
--------------------

[](#features-at-a-glance)

FeatureWhat You Get**CQRS**CommandBus, QueryBus, handler auto-discovery via compiler pass**Event-Driven**EventBus, listener auto-discovery, multi-listener**Event Sourcing**DBAL EventStore, SnapshotStore, schema SQL**Saga**DBAL SagaStore, `solidframe:saga:status`**Modular**Module auto-discovery, registry, `solidframe:module:list`**Generators**10 `make:*` commands for DDD, CQRS, events, sagas, modulesHandler Auto-Discovery
----------------------

[](#handler-auto-discovery)

SolidFrame discovers your handlers at compile time via `HandlerDiscoveryCompilerPass`.

```
// src/Application/Handler/PlaceOrderHandler.php
final readonly class PlaceOrderHandler implements CommandHandler
{
    public function __invoke(PlaceOrder $command): void { /* ... */ }
}

// No service tags needed. Inject and use:
$commandBus->dispatch(new PlaceOrder('order-123', 'customer-456'));
```

Handlers are discovered by marker interfaces (`CommandHandler`, `QueryHandler`, `EventListener`) and their `__invoke()` type hints.

Configuration
-------------

[](#configuration)

```
# config/packages/solid_frame.yaml
solid_frame:
    discovery:
        enabled: true
        paths: ['src']

    cqrs:
        command_bus:
            middleware: []
        query_bus:
            middleware: []

    event_driven:
        event_bus:
            middleware: []

    event_sourcing:
        event_store:
            driver: dbal          # 'dbal' or 'in_memory'
            connection: null       # null = default DBAL connection
            table: event_store
        snapshot_store:
            driver: dbal
            connection: null
            table: snapshots

    saga:
        store:
            driver: dbal
            connection: null
            table: sagas

    modular:
        path: modules
        auto_discovery: true
```

Console Commands
----------------

[](#console-commands)

### Generators

[](#generators)

```
# DDD
php bin/console make:entity Order
php bin/console make:value-object Email
php bin/console make:aggregate-root Order

# CQRS
php bin/console make:cqrs-command PlaceOrder --handler
php bin/console make:command-handler PlaceOrderHandler --command-class=PlaceOrder
php bin/console make:query GetOrderById --handler
php bin/console make:query-handler GetOrderByIdHandler --query-class=GetOrderById

# Event-Driven
php bin/console make:domain-event OrderPlaced --listener
php bin/console make:event-listener SendOrderConfirmation --event-class=OrderPlaced

# Saga
php bin/console make:saga PlaceOrderSaga

# Module
php bin/console make:module Order
```

All generators support subdirectories: `php bin/console make:entity Order/OrderItem`

### Operational

[](#operational)

```
# List registered modules
php bin/console solidframe:module:list

# View saga details
php bin/console solidframe:saga:status {saga-id}
```

Database Schema
---------------

[](#database-schema)

SQL schema files for DBAL stores are included in the package. Create the tables manually or via your migration system:

**Event Store** (`event_store`):

- `aggregate_id`, `version`, `event_type`, `payload` (JSON), `occurred_at`
- Unique constraint on `(aggregate_id, version)` for optimistic concurrency

**Snapshots** (`snapshots`):

- `aggregate_id`, `aggregate_type`, `version`, `state` (JSON)

**Sagas** (`sagas`):

- `id`, `saga_type`, `status`, `associations` (JSON), `state` (serialized)

Modular Monolith
----------------

[](#modular-monolith)

### Create a Module

[](#create-a-module)

```
php bin/console make:module Inventory
```

### Module Definition

[](#module-definition)

```
use SolidFrame\Modular\Module\AbstractModule;

final class InventoryModule extends AbstractModule
{
    public function __construct()
    {
        parent::__construct(
            name: 'inventory',
            dependsOn: ['catalog'],
        );
    }
}
```

When `solid_frame.modular.auto_discovery` is `true`, modules are discovered from `*Module.php` files in the configured path and registered automatically.

```
php bin/console solidframe:module:list
```

Middleware
----------

[](#middleware)

Add middleware to buses via config:

```
solid_frame:
    cqrs:
        command_bus:
            middleware:
                - App\Middleware\TransactionMiddleware
                - App\Middleware\LoggingMiddleware
```

Middleware classes are resolved from the service container.

DI Services
-----------

[](#di-services)

The bundle registers these services:

InterfaceImplementation`CommandBusInterface``CommandBus` with discovered handlers`QueryBusInterface``QueryBus` with discovered handlers`EventBusInterface``EventBus` with discovered listeners`EventStoreInterface``DbalEventStore` or `InMemoryEventStore``SnapshotStoreInterface``DbalSnapshotStore` or `InMemorySnapshotStore``SagaStoreInterface``DbalSagaStore` or `InMemorySagaStore``ModuleRegistryInterface``InMemoryModuleRegistry`All services are public for container access. Store driver falls back to in-memory when DBAL is not installed.

Requirements
------------

[](#requirements)

- PHP 8.2+
- Symfony 6.4 or 7.x

Optional packages (installed as needed):

- `solidframe/ddd` — for `make:entity`, `make:value-object`, `make:aggregate-root`
- `solidframe/cqrs` — for CommandBus, QueryBus, handler discovery
- `solidframe/event-driven` — for EventBus, listener discovery
- `solidframe/event-sourcing` — for EventStore, SnapshotStore
- `solidframe/modular` — for module support
- `solidframe/saga` — for SagaStore
- `doctrine/dbal` — for database-backed stores

Related Packages
----------------

[](#related-packages)

- [solidframe/core](../core) — Bus interfaces, Middleware
- [solidframe/ddd](../ddd) — Entity, ValueObject, AggregateRoot
- [solidframe/cqrs](../cqrs) — CommandBus, QueryBus
- [solidframe/event-driven](../event-driven) — EventBus, Listeners
- [solidframe/event-sourcing](../event-sourcing) — EventStore, Snapshots
- [solidframe/modular](../modular) — Module contracts
- [solidframe/saga](../saga) — Saga lifecycle
- [solidframe/laravel](../laravel) — Laravel alternative

Contributing
------------

[](#contributing)

This repository is a read-only split of the [solidframe/solidframe](https://github.com/solidframe/solidframe) monorepo, auto-synced on every push to `main`. Issues, pull requests, and discussions belong in the monorepo.

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance89

Actively maintained with recent releases

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

57d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/97de2a466719393a21a8ce5caef247a1afb8aec5a8974248da0583f4197765b2?d=identicon)[abdulkadir-posul](/maintainers/abdulkadir-posul)

---

Top Contributors

[![abdulkadir-posul](https://avatars.githubusercontent.com/u/88670954?v=4)](https://github.com/abdulkadir-posul "abdulkadir-posul (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/solidframe-symfony/health.svg)

```
[![Health](https://phpackages.com/badges/solidframe-symfony/health.svg)](https://phpackages.com/packages/solidframe-symfony)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
