Skip to content

Seeder Log and Prevent/Allow duplicate execution #1758

@claude-eric-steiner

Description

@claude-eric-steiner

Hi there, maybe I didn't get something, but here my thoughts worth 5 cents:

Execution of Migrations Scripts are logged into phinxlog, and can be queried from command line with "phinx status". So track of execution is easy and duplicate execution is prevented. A really great thing!

I'm missing a bit that kind of control for the the seeders... I'm not a phinx crack, and to be honest, this tool is quite new for me, so maybe I'm missing somehting here (but couldn't find it in the docs).

Would it not be great to have also a log (and the possibility to query it with a status command from command line) for the seed executions?
Also it would be quite handy to have a property inside the seeder class to prevent or allow duplicate executions.

Of course you could add this functionallity into the each seeder itself (to write some stuff about its execution into a log table, and then later query that table to check if it was already executed), but I feel like a generic approach without a homebrew hack for this would be better...

any thoughts?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions