1VOTEQUORUM_INITIALICZoEr(o3s)ync Cluster Engine Programmer'sVMOaTnEuQaUlORUM_INITIALIZE(3)
2
3
4
6 votequorum_initialize - Create a new connection to the VoteQuorum ser‐
7 vice
8
10 #include <corosync/votequorum.h>
11
12 int votequorum_initialize(votequorum_handle_t *handle, votequorum_call‐
13 backs_t *callbacks);
14
16 The votequorum_initialize function is used to initialize a connection
17 to the vote-based quorum database API.
18
19 Each application may have several connections to the votequorum API.
20 Each application uses the handle argument to uniquely identify the con‐
21 nection. The handle argument is then used in other function calls to
22 identify the connection to be used for communication with the votequo‐
23 rum service.
24
25 Every time the voting configuraton changes (eg a node joins or leave
26 the cluster), the callback is called. The callback function is
27 described by the following type definitions:
28
29 typedef void (*votequorum_notification_fn_t) ( votequorum_handle_t
30 handle, uint64_t context, uint32_t quorate, uint32_t
31 node_list_entries, votequorum_node_t node_list[] );
32
33
34The callbacks argument is of the type:
35
36 typedef struct {
37 votequorum_notification_fn_t votequorum_notify_fn;
38 } votequorum_callbacks_t;
39
40
41When a configuration change occurs, the callback is called from the votequo‐
43
45 This call returns the CS_OK value if successful, otherwise an error is
46 returned.
47
49 Callbacks are not support at the moment.
50
52 The errors are undocumented.
53
55 votequorum_overview(8), votequorum_finalize(3), votequorum_fd_get(3),
56 votequorum_dispatch(3),
57
58corosync Man Page 2009-01-26 VOTEQUORUM_INITIALIZE(3)