Commit 1daa5e69 authored by rojer's avatar rojer Committed by Cesanta Bot

Add timestamp to LB log

PUBLISHED_FROM=61b87fcee909241d5bdf2ba7407003c0c3cfbd72
parent 17184909
......@@ -277,8 +277,9 @@ static int connect_backend(struct conn_data *conn, struct http_message *hm) {
struct mg_connection *nc = conn->client.nc;
struct http_backend *be = choose_backend(hm);
write_log("%.*s %.*s backend=%s\n", (int) hm->method.len, hm->method.p,
(int) hm->uri.len, hm->uri.p, be ? be->host_port : "not defined");
write_log("%ld %.*s %.*s backend=%s\n", (long) time(NULL),
(int) hm->method.len, hm->method.p, (int) hm->uri.len, hm->uri.p,
be ? be->host_port : "not defined");
if (be == NULL) return 0;
if (be->redirect != 0) {
......
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