The Sequence Toolkit
www.sequence-toolkit.com
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
include
stk_service_group.h
Go to the documentation of this file.
1
5
#ifndef STK_SERVICE_GROUP_H
6
#define STK_SERVICE_GROUP_H
7
#include "
stk_common.h
"
8
#include "
stk_service.h
"
9
#include "
stk_smartbeat.h
"
10
16
typedef
struct
stk_service_group_stct
stk_service_group_t
;
17
23
typedef
stk_uint64
stk_service_group_id
;
24
31
typedef
stk_uint16
stk_service_group_state
;
32
33
#define STK_SERVICE_GROUP_INIT 1
34
#define STK_SERVICE_GROUP_RUNNING 2
42
typedef stk_uint16 stk_service_in_group_state;
43
44
#define STK_SERVICE_IN_GROUP_EXPECTED 1
45
#define STK_SERVICE_IN_GROUP_JOINED 2
46
#define STK_SERVICE_IN_GROUP_ERROR 0xff
49
typedef stk_ret (*stk_service_in_group_cb)(stk_service_group_t *svc_group, stk_service_t *svc,void *clientd);
50
54
typedef
void (*
stk_service_added_cb
)(
stk_service_group_t
*svc_group,
stk_service_t
*svc,
stk_service_in_group_state
state);
59
typedef
void (*
stk_service_removed_cb
)(
stk_service_group_t
*svc_group,
stk_service_t
*svc,
stk_service_in_group_state
state);
64
typedef
void (*
stk_service_smartbeat_cb
)(
stk_service_group_t
*svc_group,
stk_service_t
*svc,
stk_smartbeat_t
*smartbeat);
65
66
#endif
67
Sequence Toolkit
API, Wed Apr 15 2015 22:32:53