On 11/11/10 03:59 PM, Danek Duvall wrote:
Shawn Walker wrote:

I also think it would be pretty silly to move the location of the image
version in the structure as that would defeat the whole purpose of adding
a versioning mechanism.

True, and I hope that what we have is sufficient for all time, but I tend
to think that very few things are.

Keep in mind that with the pkg.config classes I've abstracted out how exactly configuration is serialised/deserialised so that this is far more robust than it used to be when it comes to configuration changes.

I felt it was best for the client to try as hard as possible to make the
image useable rather than simply fail.  But if you want me to change the
path where I'm falling back to trying to detect the type of image based
on structure, and the image looks like it's a version 4 (or possibly
newer) image, and have the client fail with an exception, I'm willing to
compromise and do that.

I'm completely fine using the image structure to determine an image's
version, as long as the version we get is v2/v3 (or whatever versions we've
already produced that didn't have explicit versions).

I'm much less comfortable using image structure to determine the image
version if it's a version we know should have a version number stored
somewhere, but we couldn't find it.

In particular, trying to determine the difference between a broken image
(which we could then try to repair) and an image which is too new for us to
recognize (at which point we should throw up our hands) seems dicey.  If
you can explain why you're comfortable with that, perhaps I could be
persuaded.

In part because I'm not expecting a change in image format for quite a while, and in part because the client has been so strict about image structure in the past, that if "one little thing" went wrong, it would traceback and you couldn't do anything at all.

Now admittedly, the current behaviour in the event I find an image that is > v3 could be something reserved for 'pkg fix' or 'pkg verify'. It certainly doesn't have to be an automatic thing.

As I said before, I'm willing to change this particular part if that's the desired direction.

-Shawn
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss

Reply via email to