summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfengweihao <[email protected]>2021-09-22 15:25:05 +0800
committer冯伟浩 <[email protected]>2021-10-12 06:15:37 +0000
commitffd2ca67341742c2a98bd53b8db7c05ca6f862a6 (patch)
tree0d783d1bfa50fefebb5b7f2bcdc6f7be3a653a84
parentc3cead1d8430354125b0f56e8eb84108af0dbcde (diff)
TSG-7844 支持分别记录请求侧和应答侧的content_type和lengthv4.5.16-202110
-rw-r--r--plugin/business/pangu-http/src/pangu_logger.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/plugin/business/pangu-http/src/pangu_logger.cpp b/plugin/business/pangu-http/src/pangu_logger.cpp
index 56d0b17..107a9cb 100644
--- a/plugin/business/pangu-http/src/pangu_logger.cpp
+++ b/plugin/business/pangu-http/src/pangu_logger.cpp
@@ -126,10 +126,12 @@ int pangu_send_log(struct pangu_logger* handle, const struct pangu_log* log_msg)
struct json_spec req_fields[]={ {"http_cookie", TFE_HTTP_COOKIE},
{"http_referer", TFE_HTTP_REFERER},
- {"http_user_agent", TFE_HTTP_USER_AGENT} };
+ {"http_user_agent", TFE_HTTP_USER_AGENT},
+ {"http_request_content_type", TFE_HTTP_CONT_TYPE},
+ {"http_request_content_length", TFE_HTTP_CONT_LENGTH}};
- struct json_spec resp_fields[]={ {"http_content_type", TFE_HTTP_CONT_TYPE},
- {"http_content_length", TFE_HTTP_CONT_LENGTH},
+ struct json_spec resp_fields[]={ {"http_response_content_type", TFE_HTTP_CONT_TYPE},
+ {"http_response_content_length", TFE_HTTP_CONT_LENGTH},
{"http_set_cookie", TFE_HTTP_SET_COOKIE}};
if (!handle->en_sendlog)