ibexa/doctrine-schema
A Symfony bundle providing a cross-DBMS schema import abstraction layer. It defines a custom YAML schema format and autowired APIs, plus an event-driven SchemaBuilder and interfaces for importing and exporting Doctrine DBAL schema objects.
Schema objects and back again, which means one schema artifact can target MySQL/MariaDB, PostgreSQL, and other platforms without hand-maintained per-vendor SQL. The build alternative — writing your own YAML-to-DBAL importer plus platform resolution — is roughly a one-to-two engineer-week effort plus permanent maintenance, so the calculus only favors buying if the package is already in your dependency graph.SchemaBuilder is event-driven and extensible: modules contribute schema at build time. That is a genuine architectural asset if the product strategy involves optional modules, tenant-specific extensions, or a marketplace of add-ons. If the strategy is a single monolithic deploy, this capability is unused weight.Schema object — useful for documentation generation, drift detection between environments, and reviewing schema changes in code review rather than in opaque migrations.Consider it when:
Schema → export) for drift checks.DatabasePlatformResolver) that smooths over cross-version DBAL differences — non-trivial to get right yourself.Look elsewhere when:
NOASSERTION — legal review is mandatory, not optional, before this enters a dependency manifest.For executives — one paragraph: This is a small, focused component from the Ibexa DXP platform that lets us define our database schema once, in a readable YAML file, and target multiple database engines from that single definition. It matters if — and only if — multi-database support or a modular, plug-in product architecture is on the roadmap. It is not a general-purpose library: it is dual-licensed under the Ibexa commercial license or GPL-2.0, which means adopting it outside an existing Ibexa subscription carries real legal cost and a copyleft obligation. The recommendation is to adopt it only if we are already Ibexa customers, or if we are prepared to accept GPL-2.0 terms; otherwise the honest comparison is one to two engineer-weeks to build an equivalent internal layer under our own license.
For engineering — the substantive case: It provides three autowired Symfony services — SchemaImporterInterface (YAML → Doctrine\DBAL\Schema), SchemaExporterInterface (Schema → YAML), and SchemaBuilderInterface (event-driven assembly of multiple schema sources). The SchemaBuilder event pattern is the interesting part: SchemaBuilderEvents::BUILD_SCHEMA lets each module or bundle contribute its own schema file at a defined priority, so schema composition scales with the module system instead of accumulating in one migration directory. It also handles DBAL platform detection across versions, which is the part that always breaks when you support more than one database.
The caveats to state plainly in the same breath: the YAML format is undocumented outside the source, the repo has four stars and zero dependents, releases are almost entirely housekeeping, and the license requires legal sign-off. This is vendor infrastructure we would be riding, not a community library we would be investing in. Frame the decision as "are we an Ibexa shop?" — if yes, this is free leverage; if no, this is a licensing and maintenance liability that a modest internal build would avoid.
How can I help you explore Laravel packages today?