[wp-hackers] Plugin Authors: Major Plugin Upgrade Question
johnbillion+wp at gmail.com
Mon Apr 9 18:45:43 UTC 2012
On 9 April 2012 17:47, Scott Kingsley Clark <scott at skcdev.com> wrote:
> I've got a pretty beefy question for plugin authors. I'm getting ready
> to release a major new version of one of my plugins, but really don't
> know how to handle the upgrade as I've never attempted anything of
> this scale for any of my plugins in the past.
> There's a lot of DB changes, a big codebase change (refactor), etc..
Is this an update to Pods by any chance?
> Or how should I handle the upgrade? Do I try to figure out some
> complex workaround to keep sites functional up until the upgrade
> script is run (once they've upgraded to the new major version)?
What sort of DB changes are being made? Can the operations to perform
the DB changes be chunked? In an ideal world, the new version of the
plugin would continue to support the old database schema. This would
allow the new version to be installed but without the need to run the
DB schema upgrade immediately. Not necessarily the easiest option, but
the most user-friendly.
The plugin would then display a notice on every admin screen stating
that an upgrade routine needs to be performed. An admin screen which
uses AJAX would fire off incremental updates to your DB structure,
providing feedback as it goes. The WordPress Multisite upgrade screen
does this, as do several plugins such as Viper007Bond's Regenerate
More information about the wp-hackers