[Dbix-class] Please review my proposed CPAN Module: DBIx-Class-Schema-VersionCheck

Stefan Hornburg (Racke) racke at linuxia.de
Wed Jan 25 08:54:32 GMT 2017

On 01/24/2017 11:40 PM, Matt S Trout wrote:
> On Fri, Jan 06, 2017 at 03:17:58PM +0100, Stefan Hornburg (Racke) wrote:
>> I created a module to support scripting:
>> https://metacpan.org/pod/DBIx::Class::DeploymentHandler::CLI
> I'd love to see any missing features added to the App::DH that I wrote
> a few years back unless there's a compelling reason to have two.

OK, I'll check that out ...

>> I also coded a helper for custom scripts, which are also a fantastic
>> part of DeploymentHandler, but you can't easily test them right
>> now. This will be part of a subsequent release.
> Do please discuss your ideas for that on here - maybe they can be rolled
> into DeploymentHandler so they're available to all users thereof?

Currently I'm working on a larger and complicated migration,
so I'm going through a lot of iterations.

Changing schema and/or custom script, prepare the DH files
and run the upgrade.

So basically I run the following script after resetting the database:

git clean -df sql


./bin/install-custom --before-sql InvalidValues
./bin/install-custom --before-sql FixDanglingRecords
./bin/install-custom MergeAccounts


InvalidValues, FixDanglingRecords and MergeAccounts are Perl
modules in the Foo::Schema::Upgrades namespace.

I can also run an individual script with

./bin/run-custom MergeAccounts

The next step is to put these scripts and support for them in the ::CLI
module and after that we can check whether we can roll that into DeploymentHandler.

How does that sound?


Ecommerce and Linux consulting + Perl and web application programming.
Debian and Sympa administration.

More information about the DBIx-Class mailing list