Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ git_repository(
)

# When updating envoy sha manually please update the sha in istio.deps file also
ENVOY_SHA = "d55f4990889da5d6874ab70ec5f4e5e0a9053160"
ENVOY_SHA = "d338e45e31be628f19c895003d0aeee6be18d32f"

http_archive(
name = "envoy",
Expand Down
2 changes: 1 addition & 1 deletion istio.deps
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@
"repoName": "envoyproxy/envoy",
"prodBranch": "master",
"file": "WORKSPACE",
"lastStableSHA": "d55f4990889da5d6874ab70ec5f4e5e0a9053160"
"lastStableSHA": "d338e45e31be628f19c895003d0aeee6be18d32f"
}
]
2 changes: 2 additions & 0 deletions src/envoy/http/authn/filter_context.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
#include "authentication/v1alpha1/policy.pb.h"
#include "common/common/logger.h"
#include "envoy/config/filter/http/authn/v2alpha1/config.pb.h"
#include "envoy/http/header_map.h"
#include "envoy/network/connection.h"
#include "src/istio/authn/context.pb.h"

namespace Envoy {
Expand Down
1 change: 1 addition & 0 deletions src/envoy/http/jwt_auth/token_extractor.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

#include "common/common/logger.h"
#include "envoy/config/filter/http/jwt_authn/v2alpha/config.pb.h"
#include "envoy/http/header_map.h"

namespace Envoy {
namespace Http {
Expand Down
4 changes: 3 additions & 1 deletion src/envoy/http/mixer/filter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@ void Filter::onDestroy() {

void Filter::log(const HeaderMap* request_headers,
const HeaderMap* response_headers,
const HeaderMap* response_trailers,
const RequestInfo::RequestInfo& request_info) {
ENVOY_LOG(debug, "Called Mixer::Filter : {}", __func__);
if (!handler_) {
Expand All @@ -227,7 +228,8 @@ void Filter::log(const HeaderMap* request_headers,
handler_->ExtractRequestAttributes(&check_data);
}
// response trailer header is not counted to response total size.
ReportData report_data(response_headers, request_info, request_total_size_);
ReportData report_data(response_headers, response_trailers, request_info,
request_total_size_);
handler_->Report(&report_data);
}

Expand Down
1 change: 1 addition & 0 deletions src/envoy/http/mixer/filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ class Filter : public Http::StreamDecoderFilter,
// Called when the request is completed.
virtual void log(const HeaderMap* request_headers,
const HeaderMap* response_headers,
const HeaderMap* response_trailers,
const RequestInfo::RequestInfo& request_info) override;

private:
Expand Down
7 changes: 5 additions & 2 deletions src/envoy/http/mixer/report_data.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,18 @@ class ReportData : public ::istio::control::http::ReportData {
uint64_t request_total_size_;

public:
ReportData(const HeaderMap *headers, const RequestInfo::RequestInfo &info,
uint64_t request_total_size)
ReportData(const HeaderMap *headers, const HeaderMap *response_trailers,
const RequestInfo::RequestInfo &info, uint64_t request_total_size)
: headers_(headers),
info_(info),
response_total_size_(info.bytesSent()),
request_total_size_(request_total_size) {
if (headers != nullptr) {
response_total_size_ += headers->byteSize();
}
if (response_trailers != nullptr) {
response_total_size_ += response_trailers->byteSize();
}
}

std::map<std::string, std::string> GetResponseHeaders() const override {
Expand Down