On 11/17/10 03:53 PM, Edward Pilatowicz wrote:
On Wed, Nov 17, 2010 at 11:10:13AM -0800, Shawn Walker wrote:
On 11/17/10 10:48 AM, Shawn Walker wrote:
On 11/17/10 09:33 AM, Edward Pilatowicz wrote:
i'm confused as to why we're going to have both PKG_CACHEDIR and
PKG_CACHEROOT, and what the functional difference between the two is.
the comments are the same for both, but only PKG_CACHEDIR entries get
appended to __read_cache_dirs?
PKG_CACHEDIR expects a flat cache directory as that was it's historical
behaviour.
PKG_CACHEROOT expects a tree cache directory that's structured like
/var/pkg/publisher.
The comments are not the same for both where it's used. I'm happy to add
comments where it's declared if that's the issue at hand.
And yes, if you'll look at the implementation, the PKG_CACHEROOT is not
appended to read_cache_dirs directly because it's a not a global, flat
cache structure. Instead, the get_cachedirs() method on the image uses
the cache root to build a cache path for each publisher.
I've updated the webrev (in place) with new comments in
modules/client/image.py to help clarify.
thanks. this looks good to me.
my only comment is that with this change, since zones will be using
PKG_CACHEROOT, zones doesn't have any dependance on PKG_CACHEDIR. so if
dropping PKG_CACHEDIR support would allow you to simplify things then
from a zones perspective you should feel free to go ahead and do this.
(but i'm guessing you're keeping it around for other reasons.)
Yes, for those that had a flat cache somewhere still or were using this
(admittedly undocumented) feature.
It costs very little to support both, so I figured it didn't matter.
Thanks,
-Shawn
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss