I'm not sure I trust that quoted error message below. I did some more testing just now and came with a different set of errors. So, starting again:
The existing app is using DBIC 0.08123 and the need to share objects with newer dbic -- and I've tested with 0.08198_01 and 0.08196. First, I set this in my apps because the DBIC objects are being places in a session (meaning I'm not explicitly calling the thaw() method in DBIC: $DBIx::Class::ResultSourceHandle::thaw_schema = $schema; Both versions work fine to freeze/thaw in their own version, but what breaks is trying to thaw the other versions serialized objects. When 0.08123 tries to thaw an object frozen with 0.08198_01 I get this: No STORABLE_thaw defined for objects of class Tii::DB::ResultSet (even after a "require Tii::DB::ResultSet;") at ../../lib/Storable.pm (autosplit into ../../lib/auto/Storable/_retrieve.al) line 380 And going the other direction when 0.08198_01 tries to thaw an object from 0.08123 I get: DBIx::Class::ResultSet::first(): Unable to perform storage-dependent operations with a detached result source (source '_unnamed_' is not associated with a schema). which I thought $DBIx::Class::ResultSourceHandle::thaw_schema would fix. I feeling a bit stuck. I really need to be able to have mixed DBIC versions running at the same time. Only thing I can think of is to hunt down every place an object is serialized and thawed and just store an ID and then refetch from the database on thaw. Kind of defeats the entire purpose of caching these in the first place. Any ideas? On Fri, Aug 17, 2012 at 5:12 PM, Bill Moseley <mose...@hank.org> wrote: > I need some ideas how to deal with this issue: > > We serialize DBIC objects with Storable and they get shared. I have a > situation where I have some machines running current DBIC and some running > much older DBIC. But, the objects are not compatible between versions of > DBIC. > > For example, .08123 (yes, two years old) trying to deserialize from > current DBIC generates: > > No STORABLE_thaw defined for objects of class DBIx::Class::Re > sultSource::Table (even after a "require DBIx::Class::ResultSource::Table;") > at ../../lib/Storable.pm (autosplit into ../../lib/auto/Storable/_ > retrieve.al) line 380 > > > And a similar problem going the other direction. > > Any ideas how to make current DBIC and such an old version work together > until we can get all our servers upgraded? > > > -- > Bill Moseley > mose...@hank.org > -- Bill Moseley mose...@hank.org
_______________________________________________ List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class IRC: irc.perl.org#dbix-class SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/ Searchable Archive: http://www.grokbase.com/group/dbix-class@lists.scsys.co.uk