Commit 7c4fe002 authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Make updatehealth an optional method for backends


git-svn-id: http://www.varnish-cache.org/svn/trunk/varnish-cache@1961 d4fa192b-c00b-0410-8231-f00ffab90ce4
parent 1872caf9
......@@ -242,8 +242,8 @@ VBE_UpdateHealth(struct sess *sp, struct vbe_conn *vc, int a)
CHECK_OBJ_NOTNULL(vc->backend, BACKEND_MAGIC);
b = vc->backend;
AN(b->method);
AN(b->method->updatehealth);
b->method->updatehealth(sp, vc, a);
if(b->method->updatehealth != NULL)
b->method->updatehealth(sp, vc, a);
CHECK_OBJ_NOTNULL(b, BACKEND_MAGIC);
}
......
......@@ -347,21 +347,6 @@ bes_GetHostname(struct backend *b)
/*--------------------------------------------------------------------*/
static void
bes_UpdateHealth(struct sess *sp, struct vbe_conn *vc, int a)
{
(void)sp;
(void)vc;
(void)a;
/*
* Not of any use for simple backend. The global health
* parameter of the backend should be enough.
*/
}
/*--------------------------------------------------------------------*/
static void
bes_Init(void)
{
......@@ -376,7 +361,6 @@ struct backend_method backend_method_simple = {
.close = bes_ClosedFd,
.recycle = bes_RecycleFd,
.gethostname = bes_GetHostname,
.updatehealth = bes_UpdateHealth,
.cleanup = bes_Cleanup,
.init = bes_Init
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment