aeruz/app-registry-bundle
Laravel bundle that provides an application registry: register apps/services, store metadata and configuration, and expose lookup/management utilities for integrations and multi-app environments. Useful for keeping app definitions centralized and discoverable across your system.
symfony/http-foundation, symfony/console) or a Laravel-compatible facade (e.g., spatie/symfony or custom wrappers).DependencyInjection (DI) is powerful for dynamic service registration. Laravel’s ServiceProvider and Container can mirror this with minimal abstraction.RegistryInterface) behind Laravel’s ServiceProvider.EventDispatcher; Laravel uses Events. May need a bridge (e.g., symfony/event-dispatcher + Laravel’s Event system).Config system. Laravel’s Illuminate/Database or Illuminate/Config can replace this with minimal changes.Route system or Laravel Sanctum/Passport can integrate with it.| Risk Area | Severity | Mitigation Strategy |
|---|---|---|
| Symfony Dependency Bloat | High | Use symfony/flex or symfony/recipes to isolate dependencies. Avoid pulling in unused Symfony components. |
| DI Container Conflicts | Medium | Laravel’s container is PSR-11 compliant; test for collisions with Symfony’s ContainerInterface. |
| Event System Mismatch | Medium | Implement a dual-event dispatcher (e.g., SymfonyEventDispatcher + LaravelEventDispatcher). |
| Performance Overhead | Low | Benchmark registry lookups vs. native Laravel solutions (e.g., cached config('services')). |
| Maintenance Burden | Medium | Assign a "Symfony Integration Lead" to manage drift between Laravel and Symfony updates. |
config/cache for lightweight use cases?aeruz/app-registry-bundle actively maintained? If not, is a fork or rewrite justified?ServiceRegistry + Illuminate/Contracts) been prototyped and rejected?Laravel Router + registry-driven middleware).config('services') instead).Phase 1: Proof of Concept (PoC)
symfony/framework-bundle (or minimal dependencies) via Composer.ServiceProvider that bootstraps the Symfony bundle’s Registry component.spatie/symfony (if available) or custom SymfonyBridge package.Phase 2: Adapter Layer
Illuminate/Contracts/ServiceRegistry wrapper for the Symfony RegistryInterface.EventDispatcher with Laravel’s Events (or vice versa).Database or Cache instead of Doctrine.// app/Providers/SymfonyRegistryProvider.php
public function register()
{
$this->app->singleton('symfony.registry', function ($app) {
$registry = new AeruzRegistry();
$registry->setStorage(new LaravelCacheAdapter($app['cache']));
return $registry;
});
}
Phase 3: Full Integration
HttpFoundation with Laravel’s Illuminate/Http.Route system for registry-driven API endpoints.Artisan commands, Horizon monitoring).Route::get('/services/{name}', function ($name) {
return response()->json(app('symfony.registry')->get($name));
});
| Component | Compatibility Notes |
|---|---|
| Symfony DI Container | Laravel’s container is PSR-11; test for binding conflicts. Use symfony/dependency-injection sparingly. |
| Doctrine DBAL | Replace with Laravel’s DB facade or Illuminate/Database/Eloquent. |
| Symfony Console | Use Laravel’s Artisan commands instead of Symfony’s Application. |
| EventDispatcher | Bridge to Laravel’s Events or use symfony/event-dispatcher directly. |
| HTTP Layer | Replace HttpFoundation with Illuminate/Http or use a middleware adapter. |
replace or provide to avoid pulling in unused Symfony bundles.php artisan registry:list).symfony/http-kernel vs. Laravel’s illuminate/http).composer.json overrides or a monorepo structure to manage versions.Xdebug with a dual-framework IDE setup (e.g., PHPStorm with Symfony/Laravel plugins).illuminate/container docs for integration.How can I help you explore Laravel packages today?