On Thu, Jul 16, 2009 at 01:35:14PM -0700, Brock Pytlik wrote: > [email protected] wrote: >> On Wed, Jul 15, 2009 at 07:48:34PM -0700, Brock Pytlik wrote: >> >>> Webrev: >>> http://cr.opensolaris.org/~bpytlik/ips-10046-v1/ >>> >>> Bug: >>> client always rereads dictionaries >>> http://defect.opensolaris.org/bz/show_bug.cgi?id=10046 >>> >> >> I think this is okay. The only question I had pertains to >> set_file_handle() and should_reread(). Does set_file_handle() get >> called each time we re-read the data? If so, no worries. If not, how >> do you ensure that should_reread() doesn't always return True if the >> file changes once? >> >> -j >> > This is somewhat complicated to explain, but, a particular IndexStore* > object, in the current use model, once it's been set to a particular > file, isn't allowed to be reused. should_reread is used to indicate to > the containing context that the file handle is out of date and a new one > must/should be constructed, pointing to the same file. The reasons for > this setup are both complicated and opaque and have to do with ensuring > consistency among the different IndexStores without taking a performance > hit. Maybe there's an obvious reorganization of the code that will make > everything saner, but I haven't seen it yet.
Would it be correct to paraphrase the answer as: it's not a problem because once should_reread() returns True, you'll create a new object with the up-to-date values from set_file_handle() and throw away the old one? If so, then that's good enough for me. -j _______________________________________________ pkg-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/pkg-discuss
