Skip to content

Commit

Permalink
mobile: Fix a typo (envoyproxy#31709)
Browse files Browse the repository at this point in the history
Signed-off-by: Fredy Wijaya <[email protected]>
  • Loading branch information
fredyw authored Jan 8, 2024
1 parent d6d45bb commit 3699419
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions mobile/library/common/http/client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
#include "source/common/http/utility.h"

#include "library/common/bridge/utility.h"
#include "library/common/buffer/bridge_fragment.h"
#include "library/common/common/system_helper.h"
#include "library/common/data/utility.h"
#include "library/common/http/header_utility.h"
Expand All @@ -28,7 +27,7 @@ namespace Http {

namespace {

constexpr auto SlowCallbackWarningTreshold = std::chrono::seconds(1);
constexpr auto SlowCallbackWarningThreshold = std::chrono::seconds(1);

} // namespace

Expand Down Expand Up @@ -87,7 +86,7 @@ void Client::DirectStreamCallbacks::encodeHeaders(const ResponseHeaderMap& heade

callback_time_ms->complete();
auto elapsed = callback_time_ms->elapsed();
if (elapsed > SlowCallbackWarningTreshold) {
if (elapsed > SlowCallbackWarningThreshold) {
ENVOY_LOG_EVENT(warn, "slow_on_headers_cb", std::to_string(elapsed.count()) + "ms");
}

Expand Down Expand Up @@ -173,7 +172,7 @@ void Client::DirectStreamCallbacks::sendDataToBridge(Buffer::Instance& data, boo

callback_time_ms->complete();
auto elapsed = callback_time_ms->elapsed();
if (elapsed > SlowCallbackWarningTreshold) {
if (elapsed > SlowCallbackWarningThreshold) {
ENVOY_LOG_EVENT(warn, "slow_on_data_cb", std::to_string(elapsed.count()) + "ms");
}

Expand Down Expand Up @@ -214,7 +213,7 @@ void Client::DirectStreamCallbacks::sendTrailersToBridge(const ResponseTrailerMa

callback_time_ms->complete();
auto elapsed = callback_time_ms->elapsed();
if (elapsed > SlowCallbackWarningTreshold) {
if (elapsed > SlowCallbackWarningThreshold) {
ENVOY_LOG_EVENT(warn, "slow_on_trailers_cb", std::to_string(elapsed.count()) + "ms");
}

Expand Down Expand Up @@ -282,7 +281,7 @@ void Client::DirectStreamCallbacks::onComplete() {

callback_time_ms->complete();
auto elapsed = callback_time_ms->elapsed();
if (elapsed > SlowCallbackWarningTreshold) {
if (elapsed > SlowCallbackWarningThreshold) {
ENVOY_LOG_EVENT(warn, "slow_on_complete_cb", std::to_string(elapsed.count()) + "ms");
}
}
Expand Down Expand Up @@ -339,7 +338,7 @@ void Client::DirectStreamCallbacks::sendErrorToBridge() {

callback_time_ms->complete();
auto elapsed = callback_time_ms->elapsed();
if (elapsed > SlowCallbackWarningTreshold) {
if (elapsed > SlowCallbackWarningThreshold) {
ENVOY_LOG_EVENT(warn, "slow_on_error_cb", std::to_string(elapsed.count()) + "ms");
}
}
Expand All @@ -366,7 +365,7 @@ void Client::DirectStreamCallbacks::onCancel() {

callback_time_ms->complete();
auto elapsed = callback_time_ms->elapsed();
if (elapsed > SlowCallbackWarningTreshold) {
if (elapsed > SlowCallbackWarningThreshold) {
ENVOY_LOG_EVENT(warn, "slow_on_cancel_cb", std::to_string(elapsed.count()) + "ms");
}
}
Expand Down

0 comments on commit 3699419

Please sign in to comment.