GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  SP_GET_MEMB_INFO (3)

NAME

SP_get_memb_info, SP_scat_get_memb_info - Extract membership information from message

CONTENTS

Synopsis
Description
Bugs
Author

SYNOPSIS

#include <sp.h>

int SP_get_memb_info( const char * memb_mess, const service service_type, membership_info *memb_info);
int SP_scat_get_memb_info( const scatter * memb_mess_scat, const service service_type, membership_info *memb_info);

DESCRIPTION

SP_get_memb_info and its scatter variant all parse the contents of a message body that is received as part of a membership message and fill in the membership_info struct that is passed in as a parameter.

The service_type and the memb_mess fields should be the same as the values returned in a previous SP_receive call for a membership message. The caller should allocate a new membership_info structure and pass that into this function. When the function returns the structure will be filled in.

The fields of a membership_info struct include

group_id gid
 
char changed_member[MAX_GROUP_NAME]
 
unsigned int num_vs_set
 
vs_set_info my_vs_set
 

The changed_member field is filled in with the name of the new or leaving member if the membership is a Join, Leave or Disconnect. If it is a Network membership event then the changed_member field is blank and multiple vs_sets will be available with all of the subsets of daemons coming together into the new membership.

The my_vs_set field stores the number of members of my local vs set, i.e. those processes who came together with me and the location of the list of members. See SP_get_vs_set_members for how to extract the full list of members. The SP_get_vs_sets_info function will return the full list of all VS sets that arrived with this membership message.

RETURN VALUES

Returns a postivive value on success or one of the following errors ( < 0 ):
ILLEGAL_MESSAGE
  The message had an illegal structure, like a scatter not filled out correctly. Or it is not a membership message.

BUGS

None.

AUTHOR

Yair Amir <yairamir@cnds.jhu.edu>
Jonathan Stanton <jonathan@cnds.jhu.edu>

SEE ALSO

libspread(3)

Search for    or go to Top of page |  Section 3 |  Main Index


SPREAD SP_GET_MEMB_INFO (3) February 2006

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.