From ac5a54e24ac79a33ddf8320811d981b950e21e8e Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 14 Apr 2009 10:22:20 -0400 Subject: Make reconnection to the Data Provider a global setting Previously, every DP client was allowed to set its own "retries" option. This option was ambiguous, and useless. All DP clients will now use a global option set in the services config called "reconnection_retries" --- server/responder/nss/nsssrv.c | 7 ++----- server/responder/pam/pamsrv.c | 4 ++-- 2 files changed, 4 insertions(+), 7 deletions(-) (limited to 'server/responder') diff --git a/server/responder/nss/nsssrv.c b/server/responder/nss/nsssrv.c index 8e72a95cb..e85e56b0a 100644 --- a/server/responder/nss/nsssrv.c +++ b/server/responder/nss/nsssrv.c @@ -297,12 +297,9 @@ int nss_process_init(TALLOC_CTX *mem_ctx, } /* Enable automatic reconnection to the Data Provider */ - - /* FIXME: "retries" is too generic, either get it from a global config - * or specify these retries are about the sbus connections to DP */ ret = confdb_get_int(nctx->rctx->cdb, nctx->rctx, - nctx->rctx->confdb_service_path, - "retries", 3, &max_retries); + SERVICE_CONF_ENTRY, + "reconnection_retries", 3, &max_retries); if (ret != EOK) { DEBUG(0, ("Failed to set up automatic reconnection\n")); return ret; diff --git a/server/responder/pam/pamsrv.c b/server/responder/pam/pamsrv.c index 1adbb14c1..e4ddc4328 100644 --- a/server/responder/pam/pamsrv.c +++ b/server/responder/pam/pamsrv.c @@ -163,8 +163,8 @@ static int pam_process_init(struct main_context *main_ctx, /* FIXME: "retries" is too generic, either get it from a global config * or specify these retries are about the sbus connections to DP */ - ret = confdb_get_int(rctx->cdb, rctx, rctx->confdb_service_path, - "retries", 3, &max_retries); + ret = confdb_get_int(rctx->cdb, rctx, SERVICE_CONF_ENTRY, + "reconnection_retries", 3, &max_retries); if (ret != EOK) { DEBUG(0, ("Failed to set up automatic reconnection\n")); return ret; -- cgit