Skip to content

Commit 4f54f4f

Browse files
committed
Set the health to unknown when exiting so that httpd
could its retry logic. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/httpd-proxy-scoreboard@428503 13f79535-47bb-0310-9956-ffa450edef68
1 parent 5a0186d commit 4f54f4f

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

support/proxymonitor.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,16 @@ int process_sharedmem(apr_pool_t *pool, int num)
202202
}
203203
return APR_SUCCESS;
204204
}
205+
/*
206+
* When stopping write health = unknown
207+
*/
208+
void markunknown_sharedmem(apr_pool_t *pool, int num)
209+
{
210+
int n;
211+
212+
for (n = 0; n < num; n++)
213+
worker_storage->set_health(n, HEALTH_UNKNOWN);
214+
}
205215

206216
/*
207217
* main
@@ -309,6 +319,8 @@ int main(int argc, const char * const argv[])
309319
apr_pool_destroy(instance);
310320
/* If something goes really wrong we should clean all, via apr_pool_destroy(instance_socket) */
311321
}
322+
if (instance_socket != NULL)
323+
markunknown_sharedmem(instance_socket, num);
312324
if (interrupted) {
313325
apr_file_printf(errfile, "Monitoring aborted due to user "
314326
"request." APR_EOL_STR);

0 commit comments

Comments
 (0)