http请求日志处理

master
chenfei 2 years ago
parent 24b3f6f6d9
commit 39ad3aaaed

@ -133,7 +133,7 @@ public class HttpUtils
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();
try try
{ {
log.info("sendPost - {}", url); // log.info("sendPost - {}", url);
URL realUrl = new URL(url); URL realUrl = new URL(url);
URLConnection conn = realUrl.openConnection(); URLConnection conn = realUrl.openConnection();
conn.setRequestProperty("accept", "*/*"); conn.setRequestProperty("accept", "*/*");
@ -152,7 +152,7 @@ public class HttpUtils
{ {
result.append(line); result.append(line);
} }
log.info("recv - {}", result); // log.info("recv - {}", result);
} }
catch (ConnectException e) catch (ConnectException e)
{ {

Loading…
Cancel
Save