PHPackages                             sunnyflail/doctrine-migration-schema-updater - 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. [Database &amp; ORM](/categories/database)
4. /
5. sunnyflail/doctrine-migration-schema-updater

ActiveLibrary[Database &amp; ORM](/categories/database)

sunnyflail/doctrine-migration-schema-updater
============================================

Simple doctrine migrations overrider

1.0.7(6mo ago)05MITPHPPHP ^8.2

Since Oct 23Pushed 6mo agoCompare

[ Source](https://github.com/SunnyFlail/doctrine-migration-schema-updater)[ Packagist](https://packagist.org/packages/sunnyflail/doctrine-migration-schema-updater)[ RSS](/packages/sunnyflail-doctrine-migration-schema-updater/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (4)Versions (8)Used By (0)

Custom Doctrine Migrations Schema Generation
============================================

[](#custom-doctrine-migrations-schema-generation)

This package provides a flexible way to introduce **custom schema generation logic** that integrates seamlessly with the `doctrine:migrations:diff` command.
Custom changes applied through this mechanism will **persist across schema updates**, ensuring your modifications are retained automatically.

---

Symfony Integration
-------------------

[](#symfony-integration)

### 1. Register the Bundle

[](#1-register-the-bundle)

Add the bundle to your `config/bundles.php` file:

```
SunnyFlail\DoctrineMigrationSchemaUpdater\Symfony\DoctrineSchemaUpdaterBundle::class => ['dev' => true],
```

Once registered, the bundle is active — but note that it does not alter your schema by default.

---

### 2. Default Schema Updater

[](#2-default-schema-updater)

The bundle includes one built-in schema updater:

[`SunnyFlail\DoctrineMigrationSchemaUpdater\SchemaUpdater\EmbeddableSchemaUpdater`](./src/SchemaUpdater/EmbeddableSchemaUpdater.php)

This updater is automatically available for dependency injection but requires additional configuration to function properly.

If you want to **modify the schema generated for entities containing embedded objects**, implement the following interface:

[`SunnyFlail\DoctrineMigrationSchemaUpdater\SchemaUpdater\UpdateEmbeddableSchemaInterface`](./src/SchemaUpdater/UpdateEmbeddableSchemaInterface.php)

Then, register your service and tag it as follows:

```
tags:
  - { name: 'doctrine.migrations.schema_updater.embeddable_schema_updater' }
```

---

### 3. Implementing Custom Schema Updaters

[](#3-implementing-custom-schema-updaters)

For more advanced schema modification logic, you can create your own schema updater by implementing:

[`SunnyFlail\DoctrineMigrationSchemaUpdater\SchemaUpdater\SchemaUpdaterInterface`](./src/SchemaUpdater/SchemaUpdaterInterface.php)

and tagging it as:

```
tags:
  - { name: 'doctrine.migrations.schema_updater.schema_updater' }
```

This allows you to define complex schema transformations that will be automatically included in the Doctrine migration diff.

---

### 4. Further Configuration

[](#4-further-configuration)

For detailed configuration options and customization possibilities, refer to the compiler pass and bundle configuration [`services.yaml`](./src/Symfony/Resources/config/services.yaml)

[`SunnyFlail\DoctrineMigrationSchemaUpdater\Symfony\DependencyInjection\CompilerPass\CustomConfigureDependencyFactoryPass`](./src/Symfony/DependencyInjection/CompilerPass/CustomConfigureDependencyFactoryPass.php)

---

✅ **Summary:**

- Integrates with Doctrine’s migration diff process.
- Preserves custom schema changes across migrations.
- Easily extendable via tagged schema updaters.

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance66

Regular maintenance activity

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 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

Every ~0 days

Total

7

Last Release

201d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/50b47ac5307f9f924ae62916c792bbfcabe962da1a0eaf68230b2199d4a6283f?d=identicon)[SunnyFlail](/maintainers/SunnyFlail)

---

Top Contributors

[![SunnyFlail](https://avatars.githubusercontent.com/u/82274752?v=4)](https://github.com/SunnyFlail "SunnyFlail (11 commits)")

###  Code Quality

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/sunnyflail-doctrine-migration-schema-updater/health.svg)

```
[![Health](https://phpackages.com/badges/sunnyflail-doctrine-migration-schema-updater/health.svg)](https://phpackages.com/packages/sunnyflail-doctrine-migration-schema-updater)
```

###  Alternatives

[damienharper/auditor-bundle

Integrate auditor library in your Symfony projects.

4542.8M](/packages/damienharper-auditor-bundle)[sonata-project/entity-audit-bundle

Audit for Doctrine Entities

644989.8k1](/packages/sonata-project-entity-audit-bundle)[pixelfederation/doctrine-resettable-em-bundle

Symfony bundle for decorating default entity managers using a resettable decorator.

20113.5k](/packages/pixelfederation-doctrine-resettable-em-bundle)[ahmed-bhs/doctrine-doctor

Runtime analysis tool for Doctrine ORM integrated into Symfony Web Profiler. Unlike static linters, it analyzes actual query execution at runtime to detect performance bottlenecks, security vulnerabilities, and best practice violations during development with real execution context and data.

813.1k](/packages/ahmed-bhs-doctrine-doctor)[opensolutions/doctrine2bridge

Adds the the power of Doctrine2 to Laravel 4 (with support for SQL logging and authentication)

133.7k](/packages/opensolutions-doctrine2bridge)

PHPackages © 2026

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