Sfoglia il codice sorgente

Remove useless APIs from coroipcs.c related to handling of overload
conditions.


git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@2146 fd59a12c-fef9-0310-b244-a6a79926bd2f

Steven Dake 17 anni fa
parent
commit
0986c30320

+ 7 - 13
exec/coroipcs.c

@@ -430,11 +430,6 @@ static inline int conn_info_destroy (struct conn_info *conn_info)
 	return (-1);
 	return (-1);
 }
 }
 
 
-struct res_overlay {
-	coroipc_response_header_t header __attribute__((aligned(8)));
-	char buf[4096];
-};
-
 union u {
 union u {
 	uint64_t server_addr;
 	uint64_t server_addr;
 	void *server_ptr;
 	void *server_ptr;
@@ -518,7 +513,7 @@ static void *pthread_ipc_consumer (void *conn)
 	struct sembuf sop;
 	struct sembuf sop;
 	int res;
 	int res;
 	coroipc_request_header_t *header;
 	coroipc_request_header_t *header;
-	struct res_overlay res_overlay;
+	coroipc_response_header_t coroipc_response_header;
 	int send_ok;
 	int send_ok;
 	unsigned int new_message;
 	unsigned int new_message;
 
 
@@ -568,13 +563,12 @@ retry_semop:
 			/*
 			/*
 			 * Overload, tell library to retry
 			 * Overload, tell library to retry
 			 */
 			 */
-			res_overlay.header.size =
-				api->response_size_get (conn_info->service, header->id);
-			res_overlay.header.id =
-				api->response_id_get (conn_info->service, header->id);
-			res_overlay.header.error = CS_ERR_TRY_AGAIN;
-			coroipcs_response_send (conn_info, &res_overlay,
-				res_overlay.header.size);
+			coroipc_response_header.size = sizeof (coroipc_response_header_t);
+			coroipc_response_header.id = 0;
+			coroipc_response_header.error = CS_ERR_TRY_AGAIN;
+			coroipcs_response_send (conn_info,
+				&coroipc_response_header,
+				sizeof (coroipc_response_header_t));
 		}
 		}
 
 
 		api->sending_allowed_release (conn_info->sending_allowed_private_data);
 		api->sending_allowed_release (conn_info->sending_allowed_private_data);

+ 1 - 14
exec/main.c

@@ -511,18 +511,6 @@ static int corosync_service_available (unsigned int service)
 	return (ais_service[service] != NULL);
 	return (ais_service[service] != NULL);
 }
 }
 
 
-static int corosync_response_size_get (unsigned int service, unsigned int id)
-{
-	return (ais_service[service]->lib_engine[id].response_size);
-
-}
-
-static int corosync_response_id_get (unsigned int service, unsigned int id)
-{
-	return (ais_service[service]->lib_engine[id].response_id);
-}
-
-
 struct sending_allowed_private_data_struct {
 struct sending_allowed_private_data_struct {
 	int reserved_msgs;
 	int reserved_msgs;
 };
 };
@@ -642,8 +630,6 @@ struct coroipcs_init_state ipc_init_state = {
 	.serialize_unlock		= serialize_unlock,
 	.serialize_unlock		= serialize_unlock,
 	.sending_allowed		= corosync_sending_allowed,
 	.sending_allowed		= corosync_sending_allowed,
 	.sending_allowed_release	= corosync_sending_allowed_release,
 	.sending_allowed_release	= corosync_sending_allowed_release,
-	.response_size_get		= corosync_response_size_get,
-	.response_id_get		= corosync_response_id_get,
 	.poll_accept_add		= corosync_poll_accept_add,
 	.poll_accept_add		= corosync_poll_accept_add,
 	.poll_dispatch_add		= corosync_poll_dispatch_add,
 	.poll_dispatch_add		= corosync_poll_dispatch_add,
 	.poll_dispatch_modify		= corosync_poll_dispatch_modify,
 	.poll_dispatch_modify		= corosync_poll_dispatch_modify,
@@ -895,6 +881,7 @@ int main (int argc, char **argv)
 		&corosync_group,
 		&corosync_group,
 		1);
 		1);
 
 
+
 	/*
 	/*
 	 * This must occur after totempg is initialized because "this_ip" must be set
 	 * This must occur after totempg is initialized because "this_ip" must be set
 	 */
 	 */

+ 0 - 6
exec/vsf_quorum.c

@@ -134,20 +134,14 @@ static struct corosync_lib_handler quorum_lib_service[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn				= message_handler_req_lib_quorum_getquorate,
 		.lib_handler_fn				= message_handler_req_lib_quorum_getquorate,
-		.response_size				= sizeof (struct res_lib_quorum_getquorate),
-		.response_id				= MESSAGE_RES_QUORUM_GETQUORATE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 1 */
 	{ /* 1 */
 		.lib_handler_fn				= message_handler_req_lib_quorum_trackstart,
 		.lib_handler_fn				= message_handler_req_lib_quorum_trackstart,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_QUORUM_NOTIFICATION,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 2 */
 	{ /* 2 */
 		.lib_handler_fn				= message_handler_req_lib_quorum_trackstop,
 		.lib_handler_fn				= message_handler_req_lib_quorum_trackstop,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_QUORUM_TRACKSTOP,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	}
 	}
 };
 };

+ 0 - 2
include/corosync/coroipcs.h

@@ -57,8 +57,6 @@ struct coroipcs_init_state {
 	int (*security_valid)(int uid, int gid);
 	int (*security_valid)(int uid, int gid);
 	void (*serialize_lock)(void);
 	void (*serialize_lock)(void);
 	void (*serialize_unlock)(void);
 	void (*serialize_unlock)(void);
-	int (*response_size_get)(unsigned int service, unsigned int id);
-	int (*response_id_get)(unsigned int service, unsigned int id);
 	int (*sending_allowed)(unsigned int service, unsigned int id,
 	int (*sending_allowed)(unsigned int service, unsigned int id,
 		const void *msg, void *sending_allowed_private_data);
 		const void *msg, void *sending_allowed_private_data);
 	void (*sending_allowed_release)(void *sending_allowed_private_data);
 	void (*sending_allowed_release)(void *sending_allowed_private_data);

+ 0 - 2
include/corosync/engine/coroapi.h

@@ -584,8 +584,6 @@ struct corosync_api_v1 {
 
 
 struct corosync_lib_handler {
 struct corosync_lib_handler {
 	void (*lib_handler_fn) (void *conn, const void *msg);
 	void (*lib_handler_fn) (void *conn, const void *msg);
-	int response_size;
-	int response_id;
 	enum cs_lib_flow_control flow_control;
 	enum cs_lib_flow_control flow_control;
 };
 };
 
 

+ 8 - 1
lib/coroipcc.c

@@ -706,10 +706,12 @@ retry_semop:
 static cs_error_t
 static cs_error_t
 coroipcc_reply_receive (
 coroipcc_reply_receive (
 	void *ipc_context,
 	void *ipc_context,
-	void *res_msg, size_t res_len)
+	void *res_msg,
+	size_t res_len)
 {
 {
 	struct sembuf sop;
 	struct sembuf sop;
 	struct ipc_segment *ipc_segment = (struct ipc_segment *)ipc_context;
 	struct ipc_segment *ipc_segment = (struct ipc_segment *)ipc_context;
+	coroipc_response_header_t *response_header;
 	int res;
 	int res;
 
 
 	/*
 	/*
@@ -733,6 +735,11 @@ retry_semop:
 		return (CS_ERR_LIBRARY);
 		return (CS_ERR_LIBRARY);
 	}
 	}
 
 
+	response_header = (coroipc_response_header_t *)ipc_segment->response_buffer;
+	if (response_header->error == CS_ERR_TRY_AGAIN) {
+		return (CS_ERR_TRY_AGAIN);
+	}
+
 	memcpy (res_msg, ipc_segment->response_buffer, res_len);
 	memcpy (res_msg, ipc_segment->response_buffer, res_len);
 	return (CS_OK);
 	return (CS_OK);
 }
 }

+ 0 - 28
services/cfg.c

@@ -191,86 +191,58 @@ static struct corosync_lib_handler cfg_lib_engine[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_ringstatusget,
 		.lib_handler_fn		= message_handler_req_lib_cfg_ringstatusget,
-		.response_size		= sizeof (struct res_lib_cfg_ringstatusget),
-		.response_id		= MESSAGE_RES_CFG_RINGSTATUSGET,
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 1 */
 	{ /* 1 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_ringreenable,
 		.lib_handler_fn		= message_handler_req_lib_cfg_ringreenable,
-		.response_size		= sizeof (struct res_lib_cfg_ringreenable),
-		.response_id		= MESSAGE_RES_CFG_RINGREENABLE,
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 2 */
 	{ /* 2 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_statetrack,
 		.lib_handler_fn		= message_handler_req_lib_cfg_statetrack,
-		.response_size		= sizeof (struct res_lib_cfg_statetrack),
-		.response_id		= MESSAGE_RES_CFG_STATETRACKSTART,
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 3 */
 	{ /* 3 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_statetrackstop,
 		.lib_handler_fn		= message_handler_req_lib_cfg_statetrackstop,
-		.response_size		= sizeof (struct res_lib_cfg_statetrackstop),
-		.response_id		= MESSAGE_RES_CFG_STATETRACKSTOP,
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 4 */
 	{ /* 4 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_administrativestateset,
 		.lib_handler_fn		= message_handler_req_lib_cfg_administrativestateset,
-		.response_size		= sizeof (struct res_lib_cfg_administrativestateset),
-		.response_id		= MESSAGE_RES_CFG_ADMINISTRATIVESTATESET,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 5 */
 	{ /* 5 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_administrativestateget,
 		.lib_handler_fn		= message_handler_req_lib_cfg_administrativestateget,
-		.response_size		= sizeof (struct res_lib_cfg_administrativestateget),
-		.response_id		= MESSAGE_RES_CFG_ADMINISTRATIVESTATEGET,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 6 */
 	{ /* 6 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_serviceload,
 		.lib_handler_fn		= message_handler_req_lib_cfg_serviceload,
-		.response_size		= sizeof (struct res_lib_cfg_serviceload),
-		.response_id		= MESSAGE_RES_CFG_SERVICELOAD,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 7 */
 	{ /* 7 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_serviceunload,
 		.lib_handler_fn		= message_handler_req_lib_cfg_serviceunload,
-		.response_size		= sizeof (struct res_lib_cfg_serviceunload),
-		.response_id		= MESSAGE_RES_CFG_SERVICEUNLOAD,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 8 */
 	{ /* 8 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_killnode,
 		.lib_handler_fn		= message_handler_req_lib_cfg_killnode,
-		.response_size		= sizeof (struct res_lib_cfg_killnode),
-		.response_id		= MESSAGE_RES_CFG_KILLNODE,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 9 */
 	{ /* 9 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_tryshutdown,
 		.lib_handler_fn		= message_handler_req_lib_cfg_tryshutdown,
-		.response_size		= sizeof (struct res_lib_cfg_tryshutdown),
-		.response_id		= MESSAGE_RES_CFG_TRYSHUTDOWN,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 10 */
 	{ /* 10 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_replytoshutdown,
 		.lib_handler_fn		= message_handler_req_lib_cfg_replytoshutdown,
-		.response_size		= sizeof (struct res_lib_cfg_replytoshutdown),
-		.response_id		= MESSAGE_RES_CFG_REPLYTOSHUTDOWN,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 11 */
 	{ /* 11 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_get_node_addrs,
 		.lib_handler_fn		= message_handler_req_lib_cfg_get_node_addrs,
-		.response_size		= sizeof (struct res_lib_cfg_get_node_addrs),
-		.response_id		= MESSAGE_RES_CFG_GET_NODE_ADDRS,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 12 */
 	{ /* 12 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_local_get,
 		.lib_handler_fn		= message_handler_req_lib_cfg_local_get,
-		.response_size		= sizeof (struct res_lib_cfg_local_get),
-		.response_id		= MESSAGE_RES_CFG_LOCAL_GET,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 13 */
 	{ /* 13 */
 		.lib_handler_fn		= message_handler_req_lib_cfg_crypto_set,
 		.lib_handler_fn		= message_handler_req_lib_cfg_crypto_set,
-		.response_size		= sizeof (struct res_lib_cfg_crypto_set),
-		.response_id		= MESSAGE_RES_CFG_CRYPTO_SET,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	}
 	}
 };
 };

+ 0 - 34
services/confdb.c

@@ -139,104 +139,70 @@ static struct corosync_lib_handler confdb_lib_engine[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_create,
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_create,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_OBJECT_CREATE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 1 */
 	{ /* 1 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_destroy,
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_destroy,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_OBJECT_DESTROY,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 2 */
 	{ /* 2 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_find,
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_find,
-		.response_size				= sizeof (struct res_lib_confdb_object_find),
-		.response_id				= MESSAGE_RES_CONFDB_OBJECT_FIND,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 3 */
 	{ /* 3 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_create,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_create,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_CREATE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 4 */
 	{ /* 4 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_get,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_get,
-		.response_size				= sizeof (struct res_lib_confdb_key_get),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_GET,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 5 */
 	{ /* 5 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_replace,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_replace,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_REPLACE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 6 */
 	{ /* 6 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_delete,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_delete,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_DELETE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 7 */
 	{ /* 7 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_iter,
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_iter,
-		.response_size				= sizeof (struct res_lib_confdb_object_iter),
-		.response_id				= MESSAGE_RES_CONFDB_OBJECT_ITER,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 8 */
 	{ /* 8 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_parent_get,
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_parent_get,
-		.response_size				= sizeof (struct res_lib_confdb_object_parent_get),
-		.response_id				= MESSAGE_RES_CONFDB_OBJECT_PARENT_GET,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 9 */
 	{ /* 9 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_iter,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_iter,
-		.response_size				= sizeof (struct res_lib_confdb_key_iter),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_ITER,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 10 */
 	{ /* 10 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_track_start,
 		.lib_handler_fn				= message_handler_req_lib_confdb_track_start,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_TRACK_START,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 11 */
 	{ /* 11 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_track_stop,
 		.lib_handler_fn				= message_handler_req_lib_confdb_track_stop,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_TRACK_STOP,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 12 */
 	{ /* 12 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_write,
 		.lib_handler_fn				= message_handler_req_lib_confdb_write,
-		.response_size				= sizeof (struct res_lib_confdb_write),
-		.response_id				= MESSAGE_RES_CONFDB_WRITE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 13 */
 	{ /* 13 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_reload,
 		.lib_handler_fn				= message_handler_req_lib_confdb_reload,
-		.response_size				= sizeof (struct res_lib_confdb_reload),
-		.response_id				= MESSAGE_RES_CONFDB_RELOAD,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 14 */
 	{ /* 14 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_find_destroy,
 		.lib_handler_fn				= message_handler_req_lib_confdb_object_find_destroy,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CONFDB_OBJECT_FIND_DESTROY,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 15 */
 	{ /* 15 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_increment,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_increment,
-		.response_size				= sizeof (struct res_lib_confdb_key_incdec),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_INCREMENT,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 16 */
 	{ /* 16 */
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_decrement,
 		.lib_handler_fn				= message_handler_req_lib_confdb_key_decrement,
-		.response_size				= sizeof (struct res_lib_confdb_key_incdec),
-		.response_id				= MESSAGE_RES_CONFDB_KEY_DECREMENT,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 };
 };

+ 0 - 10
services/cpg.c

@@ -219,32 +219,22 @@ static struct corosync_lib_handler cpg_lib_engine[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn				= message_handler_req_lib_cpg_join,
 		.lib_handler_fn				= message_handler_req_lib_cpg_join,
-		.response_size				= sizeof (struct res_lib_cpg_join),
-		.response_id				= MESSAGE_RES_CPG_JOIN,
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 1 */
 	{ /* 1 */
 		.lib_handler_fn				= message_handler_req_lib_cpg_leave,
 		.lib_handler_fn				= message_handler_req_lib_cpg_leave,
-		.response_size				= sizeof (struct res_lib_cpg_leave),
-		.response_id				= MESSAGE_RES_CPG_LEAVE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 2 */
 	{ /* 2 */
 		.lib_handler_fn				= message_handler_req_lib_cpg_mcast,
 		.lib_handler_fn				= message_handler_req_lib_cpg_mcast,
-		.response_size				= sizeof (struct res_lib_cpg_mcast),
-		.response_id				= MESSAGE_RES_CPG_MCAST,
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 3 */
 	{ /* 3 */
 		.lib_handler_fn				= message_handler_req_lib_cpg_membership,
 		.lib_handler_fn				= message_handler_req_lib_cpg_membership,
-		.response_size				= sizeof (coroipc_response_header_t),
-		.response_id				= MESSAGE_RES_CPG_MEMBERSHIP,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 4 */
 	{ /* 4 */
 		.lib_handler_fn				= message_handler_req_lib_cpg_local_get,
 		.lib_handler_fn				= message_handler_req_lib_cpg_local_get,
-		.response_size				= sizeof (struct res_lib_cpg_local_get),
-		.response_id				= MESSAGE_RES_CPG_LOCAL_GET,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	}
 	}
 };
 };

+ 0 - 10
services/evs.c

@@ -109,32 +109,22 @@ static struct corosync_lib_handler evs_lib_engine[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn				= message_handler_req_evs_join,
 		.lib_handler_fn				= message_handler_req_evs_join,
-		.response_size				= sizeof (struct res_lib_evs_join),
-		.response_id				= MESSAGE_RES_EVS_JOIN,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 1 */
 	{ /* 1 */
 		.lib_handler_fn				= message_handler_req_evs_leave,
 		.lib_handler_fn				= message_handler_req_evs_leave,
-		.response_size				= sizeof (struct res_lib_evs_leave),
-		.response_id				= MESSAGE_RES_EVS_LEAVE,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 2 */
 	{ /* 2 */
 		.lib_handler_fn				= message_handler_req_evs_mcast_joined,
 		.lib_handler_fn				= message_handler_req_evs_mcast_joined,
-		.response_size				= sizeof (struct res_lib_evs_mcast_joined),
-		.response_id				= MESSAGE_RES_EVS_MCAST_JOINED,
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 3 */
 	{ /* 3 */
 		.lib_handler_fn				= message_handler_req_evs_mcast_groups,
 		.lib_handler_fn				= message_handler_req_evs_mcast_groups,
-		.response_size				= sizeof (struct res_lib_evs_mcast_groups),
-		.response_id				= MESSAGE_RES_EVS_MCAST_GROUPS,
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_REQUIRED
 	},
 	},
 	{ /* 4 */
 	{ /* 4 */
 		.lib_handler_fn				= message_handler_req_evs_membership_get,
 		.lib_handler_fn				= message_handler_req_evs_membership_get,
-		.response_size				= sizeof (struct res_lib_evs_membership_get),
-		.response_id				= MESSAGE_RES_EVS_MEMBERSHIP_GET,
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	}
 	}
 };
 };

+ 0 - 2
services/pload.c

@@ -131,8 +131,6 @@ static struct corosync_lib_handler pload_lib_engine[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn		= message_handler_req_pload_start,
 		.lib_handler_fn		= message_handler_req_pload_start,
-		.response_size		= sizeof (struct res_lib_pload_start),
-		.response_id		= MESSAGE_RES_PLOAD_START,
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control		= CS_LIB_FLOW_CONTROL_NOT_REQUIRED
 	}
 	}
 };
 };

+ 0 - 22
services/votequorum.c

@@ -249,68 +249,46 @@ static struct corosync_lib_handler quorum_lib_service[] =
 {
 {
 	{ /* 0 */
 	{ /* 0 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_getinfo,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_getinfo,
-		.response_size				= sizeof (struct res_lib_votequorum_getinfo),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_GETINFO,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 1 */
 	{ /* 1 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_setexpected,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_setexpected,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 2 */
 	{ /* 2 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_setvotes,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_setvotes,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 3 */
 	{ /* 3 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_register,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_register,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 4 */
 	{ /* 4 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_unregister,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_unregister,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 5 */
 	{ /* 5 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_poll,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_poll,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 6 */
 	{ /* 6 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_getinfo,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_qdisk_getinfo,
-		.response_size				= sizeof (struct res_lib_votequorum_qdisk_getinfo),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_QDISK_GETINFO,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 7 */
 	{ /* 7 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_setstate,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_setstate,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 8 */
 	{ /* 8 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_leaving,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_leaving,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 9 */
 	{ /* 9 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_trackstart,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_trackstart,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	},
 	},
 	{ /* 10 */
 	{ /* 10 */
 		.lib_handler_fn				= message_handler_req_lib_votequorum_trackstop,
 		.lib_handler_fn				= message_handler_req_lib_votequorum_trackstop,
-		.response_size				= sizeof (struct res_lib_votequorum_status),
-		.response_id				= MESSAGE_RES_VOTEQUORUM_STATUS,
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 		.flow_control				= COROSYNC_LIB_FLOW_CONTROL_NOT_REQUIRED
 	}
 	}
 };
 };