On Sep 15, 2009, at 4:16 46PM, Schwab,Wilhelm K wrote: > Simon, > > I wish you well and will be eager to hear progress reports. Long > ago, I looked at ReferenceStream (or maybe SmartReferenceStream), > and did not like what I found. IIRC, the output for simple examples > was much larger (of course, it might not continue to scale so > unfavorably) compared that that produced by Dolphin's binary filer. > Another concern was schema changes. > > Dolphin has an orderly conversion process that will raise an error > if it is not prepared for what it finds; Squeak seemed to want to > fix it itself with the aid of the user (not gonna fly in an end-user > app or a server process, which is pretty much everything). > > Dolphin locates conversion methods in the class of the object being > converted or in the class of a proxy for it (that sounded scary to > me when I read about it, but it is exactly what one would want in > practice). Sounds alot like BOSS in VisualWorks :) The only annoying thing I've found using that, is the fact you never get prompted to update the conversion method when you modify a class which already contains a binaryReadBlockFrom: method. (Kind of hard to know if you store objects of the kind to disk if it doesn't have one already) Believe it or not, but it's quite easy to forget when doing some change, and you have no tests importing old variations of all the objects you file to disk in your project.
> In contrast, Squeak puts the conversion methods in ReferenceStream. > Yuk!!! Sorry, don't know what just came over me :) Of course one > can always modify ReferenceStream[*], but imagine the chaos if > ReferenceStream were to become widely used. IIRC from looking briefly at it when reviewing some removal patch which touched it, it checks first if class has conversion method, THEN it tries to autoconvert (silently if it considers itself "successful", yay). Also, if I read the code correctly, it only checks for class structure differences, so if you've, say, switched the order of two instvars since you stored an old object to disk, it'll file in just fine, but with the data in incorrect places... In short, I imagine using ReferenceStream could lead to some _very_ frustrating debugging sessions later on in the project, consider yourself warned :) Cheers, Henry _______________________________________________ Pharo-project mailing list [email protected] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
