On 27 Sep 2011, at 17:06, Ross Gardler wrote: > On 27 September 2011 16:33, Scott Wilson <[email protected]> > wrote: >> So, how best to handle this? >> >> 1. We can retain the broken method for generating hashes from 0.9.0 as a >> "legacy mode" switchable in properties >> 2. Put a big warning on the release but go ahead anyway, and promise not to >> do anything so >> 3. Bang head on keyboard repeatedly until a better idea comes up >> >> (Another option that occurred to me is to try to process each inbound widget >> instance request using the old method, and if it matches, update it to use >> the new one. Again we could toggle this on/off.) > > The last option sounds like the best, coupled with deprecation of the > old methods. > > On the 0.9.1 release we do 2. indicating that people have until the > 0.11 or 1.0 release (whichever comes sooner) to resolve this before > the deprecated behaviour is removed. During the (minimum) two release > cycles this involves it is reasonable to assume that any useful data > will have been migrated by admins. > > Note, I have a 0.8 production instance that I need to upgrade to trunk > in the next few weeks. I'm happy to make this a test site.
OK, I've added some code to migrate widget instances on an as-requested basis. So this should catch any requests for widget instances created under 0.9.0 and passively migrate them without the user noticing. In future releases we can deprecate and then remove it as Ross suggests. However I felt it important to do what we can here to maintain user's trust. I've done some limited testing using Tomcat and MySQL5; my basic procedure is: - Install Wookie 0.9.0 WAR in Tomcat - Empty DB and reset using the 0.9.0 DB script - Start Tomcat - View the Wookie demo page, and preview the Sharedraw widget, and make some squiggles - Instantiate a SimpleChat widget using the test instantiate form, and type something - Shutdown tomcat - Delete the WAR and unpacked webapp as well as any .properties and work files - Run the DB migration script - Install Wookie-0.9.1-SNAPSHOT WAR in Tomcat - Start Tomcat - Repeat step 4 and check the squiggle and chat are in place Its pretty cumbersome, so if someone can create some automated tests (and ones that go a little deeper than this...) as a way of verifying it that would be great S > > Ross > > -- > Ross Gardler (@rgardler) > Programme Leader (Open Development) > OpenDirective http://opendirective.com
