RE: [Madeleine-devel] Before the release of 0.7
Status: Beta
Brought to you by:
ndrs
From: Stephen S. <ste...@ma...> - 2004-06-28 20:14:03
|
> So the only time we really need the format detection is when=20 > someone is > using the wrong settings?.. > Couldn't we instead make it the inverse, as a fallback when the > marshaller that was set didn't work? Maybe even output a warning about > it. It feels like these safeguards shouldn't have to be used when > everything is "right". Actually I already fixed it so it detects inside the gzip. It's not exactly the wrong settings - if you are changing from one marshaller to another you might just want to start up the system with = the new marshaller setting, and have it all work nicely because it = autodetected the previous file format. I think this is quite a practical approach. =20 At the moment I detect first, and use supplied marshaller if that fails = (on the grounds that you might be changing marshaller). Alternative is to use supplied marshaller, and if that fails use = detection - I could wrap the loading using the supplied marshaller with a = begin/rescue and try to detect in the rescue. Hmm, maybe in most cases the try first then detect approach will be more efficient. Stephen. |