From 38afd84faa383c5e0be21c48c918112b7b01a5cf Mon Sep 17 00:00:00 2001 From: Anand Avati Date: Mon, 20 Aug 2012 10:19:15 -0700 Subject: rpcsvc: framework for executing actors as synctask An rpcsvc_program can be registered by setting .synctask field to 1 which will make actors of that program be executed in a synctask, thus freeing up the rpc/poll thread while the actor executes. Change-Id: Idacef2ad3bcae0f354fd0fc16ca06ba7094d7b98 BUG: 762935 Signed-off-by: Anand Avati Reviewed-on: http://review.gluster.org/3833 Tested-by: Gluster Build System Reviewed-by: Amar Tumballi --- rpc/rpc-lib/src/rpcsvc.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'rpc/rpc-lib/src/rpcsvc.h') diff --git a/rpc/rpc-lib/src/rpcsvc.h b/rpc/rpc-lib/src/rpcsvc.h index 9f526cb05..5a0ddc9da 100644 --- a/rpc/rpc-lib/src/rpcsvc.h +++ b/rpc/rpc-lib/src/rpcsvc.h @@ -224,6 +224,9 @@ struct rpcsvc_request { */ rpcsvc_auth_data_t verf; + /* Execute this request's actor function as a synctask? */ + gf_boolean_t synctask; + /* Container for a RPC program wanting to store a temp * request-specific item. */ @@ -367,6 +370,9 @@ struct rpcsvc_program { */ int min_auth; + /* Execute actor function as a synctask? */ + gf_boolean_t synctask; + /* list member to link to list of registered services with rpcsvc */ struct list_head program; }; -- cgit