This is an automated email from the ASF dual-hosted git repository.
amc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new 34727ec Improve log entry for http connect result errors
34727ec is described below
commit 34727ec4cbc4f2ce7d93c826147bfaa03c276229
Author: Xavier Chi <[email protected]>
AuthorDate: Wed Aug 1 15:46:25 2018 -0500
Improve log entry for http connect result errors
---
proxy/http/HttpSM.cc | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc
index 5c9c7d5..1c9ba38 100644
--- a/proxy/http/HttpSM.cc
+++ b/proxy/http/HttpSM.cc
@@ -5150,10 +5150,11 @@ HttpSM::mark_host_failure(HostDBInfo *info, time_t
time_down)
if (info->app.http_data.last_failure == 0) {
char *url_str =
t_state.hdr_info.client_request.url_string_get(&t_state.arena, nullptr);
- Log::error("CONNECT: could not connect to %s "
- "for '%s' (setting last failure time) connect_result=%d",
- ats_ip_ntop(&t_state.current.server->dst_addr.sa, addrbuf,
sizeof(addrbuf)), url_str ? url_str : "<none>",
- t_state.current.server->connect_result);
+ Log::error("%s", lbw()
+ .print("CONNECT: could not connect to {} for '{}'
(setting last failure time) connect_result={}\0",
+ t_state.current.server->dst_addr, url_str ?
url_str : "<none>",
+
ts::bwf::Errno(t_state.current.server->connect_result))
+ .data());
if (url_str) {
t_state.arena.str_free(url_str);