NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
Some Suggestions (Score:2)
You need some centralised locking mechanism. One developer writes a file somewhere saying "I'm altering the database" (or "I'm altering this table" if you need finer control) and then no-one else can start an update until that file is removed.
Can't you drive the changes from your sou
Re:Some Suggestions (Score:2)
They've agreed to the centralized locking mechanism. As for using source control to manage the SQL, I'm not clear as to the best way to do that. I've checked out Cvs [cpan.org] on the CPAN and I can't get the tests to pass, regardless of whether I run them through CPAN.pm or do it by hand. I admit that having CVS contain all of the changes makes for a better solution, but trying to figure out the best way to cobble all of that together with the automated database upgrades sounds problematic. Would all of the update
Re:Some Suggestions (Score:1)
Did you know that by default InnoDB will automatically increase the size of the data file as needed? That means you can specify some relatively small size to start, and the DB will automatically change it as needed. See the documentation for autoextend [mysql.com].
This probably a moot point anyway, but I wanted to point this f
"Perl users are the Greatful Dead fans of computer science." --slashdot comment
Re:Some Suggestions (Score:2)
lock tablefor some central table. I'm thinking about your config table that holds the version number, for example.Suggestions (Score:1)
Suggestion #1
To prevent simultaneous attempts to modify a schema, setup a RDBMS that can pass the ACID test (MySQL w/ InnoDB or BDB types). Stage updates on it and serialize the schema updates through it.
Su
Re: Managing Database Upgrades (Score:1)
I would make creating an update atomic. State between commands makes thing more complicated. Locking is easier when it is inside a single program.
db_update insert.sql update.sql delete.sqlHow do you deploy code changes? Database schema changes are us
Why are developers touching production systems? (Score:1)
The right place to start your question is asking how the release cycle works. Hopefully you have a development/QA/production cycle already. In that case I'd use the QA step as your useful bottleneck to make this problem tractable.
Developers in development can do whatever they like. That includes messing up their devel