Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Eventsauce Migration Generator Laravel Package

andreo/eventsauce-migration-generator

Symfony Console command that generates Doctrine Migrations for EventSauce message storage per aggregate. Configure Doctrine Migrations, then run a single command with a table prefix, selectable schemas (event/outbox/snapshot), UUID type, and optional table-name suffixes.

View on GitHub
Deep Wiki
Context7

eventsauce-migration-generator 3.0

Command to generate doctrine migrations per aggregate

About table schema

Installation

composer require andreo/eventsauce-migration-generator

Previous versions doc

Requirements

  • PHP >=8.2
  • Symfony console ^6.0

Config doctrine migrations

In the first step, configure the doctrine migrations package

Usage


use Andreo\EventSauce\Doctrine\Migration\Command\GenerateDoctrineMigrationForEventSauceCommand;

new GenerateDoctrineMigrationForEventSauceCommand(
    dependencyFactory: $dependencyFactory, // instance of Doctrine\Migrations\DependencyFactory
);

Change table name suffix


use Andreo\EventSauce\Doctrine\Migration\Command\GenerateDoctrineMigrationForEventSauceCommand;
use Andreo\EventSauce\Doctrine\Migration\Schema\TableNameSuffix;

new GenerateDoctrineMigrationForEventSauceCommand(
    dependencyFactory: $dependencyFactory,
    tableNameSuffix: new TableNameSuffix(event: 'message_store')
);

Generate command

andreo:eventsauce:doctrine-migrations:generate

Command options

prefix table name

  • required
  • string

Generate migration with foo prefix

php bin/console andreo:eventsauce:doctrine-migrations:generate foo

--schema=all

  • optional
  • string[]
  • available values: event, outbox, snapshot, all
  • default value: all

Generate migration for given schemas

php bin/console andreo:eventsauce:doctrine-migrations:generate foo --schema=event --schema=snapshot

--uuid-type=binary

  • optional
  • one of: binary, string
  • default value: binary
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky