MEDIUM: Add DRAIN state and report it on the stats page

Add a DRAIN sub-state for a server which
will be shown on the stats page instead of UP if
its effective weight is zero.

Also, log if a server enters or leaves the DRAIN state
as the result of an agent check.

Signed-off-by: Simon Horman <horms@verge.net.au>
diff --git a/src/cfgparse.c b/src/cfgparse.c
index 8c289f1..c87ca4b 100644
--- a/src/cfgparse.c
+++ b/src/cfgparse.c
@@ -4899,6 +4899,9 @@
 			}
 		}
 
+		/* Set initial drain state using now-configured weight */
+		set_server_drain_state(newsrv);
+
 		if (do_check) {
 			int ret;