[Spread-users] Order of members in vs_sets

John Lane Schultz jschultz at spreadconcepts.com
Tue Mar 31 11:30:18 EDT 2009

For membership messages, I believe the "groups" parameter, which is actually
the membership list in this case, is sorted by daemon name first and then by
client name thereafter.  So, all the members from the first daemon will be
listed first in alphabetical order, and then the clients from the second
daemon and so on.

I *think* the daemon names are also sorted by strcmp, but I'm not 100% sure.
They could be listed the order of the daemons in the configuration file
instead, for example.  I would need to look at the code.

For regular messages, the groups parameter is probably not sorted at all but
rather is simply whatever the originating client passed in as the groups
parameter.  Again, I'd need to look at the code to be sure.


John Lane Schultz
Spread Concepts LLC
Phn: 443 838 2200 

-----Original Message-----
From: Tudor Dumitras [mailto:tdumitra at andrew.cmu.edu] 
Sent: Tuesday, March 31, 2009 11:22 AM
To: John Schultz
Cc: Tudor Dumitras; spread-users at lists.spread.org
Subject: Re: [Spread-users] Order of members in vs_sets

John Schultz wrote:
> I believe each vs_set is sorted using strcmp as the comparison.  So,
> within a single vs_set I *believe* they will be sorted in ascending
> order according to strcmp.
Is this the same way the groups parameter, as returned by SP_receive(), 
is sorted?


Tudor A. Dumitras

ECE Department
Carnegie Mellon University


More information about the Spread-users mailing list