Skip to content

Commit 27f4773

Browse files
authored
Report http status code, regardless of check result (istio#357)
* report status code even on check failure * fix format
1 parent 297f222 commit 27f4773

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

mixerclient/control/src/http/attributes_builder.cc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,9 @@ void AttributesBuilder::ExtractReportAttributes(ReportData *report_data) {
141141
builder.AddInt64(AttributeName::kResponseSize, info.send_bytes);
142142
builder.AddDuration(AttributeName::kResponseDuration, info.duration);
143143
if (!request_->check_status.ok()) {
144+
builder.AddInt64(
145+
AttributeName::kResponseCode,
146+
utils::StatusHttpCode(request_->check_status.error_code()));
144147
builder.AddInt64(AttributeName::kCheckErrorCode,
145148
request_->check_status.error_code());
146149
builder.AddString(AttributeName::kCheckErrorMessage,

0 commit comments

Comments
 (0)