Re: [PATCH] util: hash: Append to hash buckets when adding new entries

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 16, 2019 at 15:32:31 +0100, Daniel Berrange wrote:
> On Tue, Apr 16, 2019 at 04:26:49PM +0200, Peter Krempa wrote:
> > On Tue, Apr 16, 2019 at 15:17:31 +0100, Daniel Berrange wrote:
> > > On Tue, Apr 16, 2019 at 04:09:54PM +0200, Peter Krempa wrote:

[...]

> > Currently there aren't any collisions which would cause problems, but I
> > have one on my private branch.
> > 
> > Given that this change is rather simple I figured we could just stop
> > inverting them.
> 
> Ok, that does make a little more sense, though generally my view would
> be that if we're doing something that is order sensitive like XML
> parsing & formatting, then we shouldn't be using a hash table to
> represent the data - at least not as the primary record. 
> 
> Which bit of code is using the hash in this case ? Is it something
> purely inside the test suite, or in the real XML handling code ?

I'm adding some private data for blockjobs which are formatted into the
status XML. I'm storing them in a hash table as the order isn't really
important here and the user should never see this.

I was just bothered by the fact that I'd need to have an output file (or
change the name of the blockjob) and figured that the insertion into the
hash table is very simple and does not really matter how we do it.

Attachment: signature.asc
Description: PGP signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux