|
From KerrighedKDDM set is the second level of naming for KDDM objects. A set of objects hosts objects of the same kind. The semantic of "same kind" is up to the Kerrighed developper. A set can host for instance:
Manipulation Functionscreate_new_kddm_setstruct kddm_set *create_new_kddm_set ( struct kddm_ns *ns, // Name space the set will belong to iolinker_id_t linker_id, // Id of the IO linker to link with the set kerrighed_node_t link, // Node linked to the set int obj_size, // Size of object strored in the set void *private_data, // Private data to link with the set unsigned long data_size, // Size of the private data. unsigned long flags ); struct kddm_set *__create_new_kddm_set ( struct kddm_ns *ns, // Name space the set will belong to kddm_set_id_t set_id, // Id of the set to create int order, // Maximum number of elements to store in the set (2^order). iolinker_id_t linker_id, // Id of the IO linker to link with the set kerrighed_node_t link, // Node linked to the set int obj_size, // Size of object strored in the ser void *private_data, // Private data to link with the set unsigned long data_size, // Size of the private data. unsigned long flags ); The create_new_kddm_set function creates a new KDDM set. During a set creation, there is no communications between nodes. The set is only created on the local node. Remote instances of the set are created lazily, on demand. When using the create_new_kddm_set function, a KDDM set id is automatically generated for the newly created set. The __create_new_kddm_set is the same as the create_new_kddm_set function, except you can force the set id. destroy_kddm_setint destroy_kddm_set ( struct kddm_set * kddm_set // The KDDM set to destroy. ); The destroy_kddm_set function destroys a KDDM set. The set and all objects belonging to the set are freed. find_get_kddm_setstruct kddm_set *find_get_kddm_set ( int ns_id, // Name space ID to look up the set in. ctnrid_t set_id // Id of the set to lookup for. ); struct kddm_set *_find_get_kddm_set ( struct kddm_ns *ns // Name space to look up the set in. ctnrid_t set_id // Id of the set to lookup for. ); The find_get_kddm_set function search for a given set in a given name space. The structure of the set is returned. The find_get_kddm_set function takes a name space id as an argument since the __find_get_kddm_set takes a name space structure as an argument.
put_kddm_setvoid put_kddm_set ( struct kddm_set *set // The kddm set to put. ); The put_kddm_set function releases a KDDM set structure.
|