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
4 changes: 2 additions & 2 deletions bazel/repositories.bzl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

ENVOY_COMMIT = "031f75dd113e2f7be41b94a0365145e7bf1e6c12" # March 14th, 2021
ENVOY_SHA = "20f5f98cc9a5c1ddd2c3de434b019273e3dbe02afe52396b90d74fab38dba4ba"
ENVOY_COMMIT = "ff3b5e3ce3f8916aab88b573678826e6fd95e01c" # March 22, 2021
ENVOY_SHA = "683601fd7f003c50f8783b2d576f68d7c02d57c7ad123b88e6caf45cc3292dd9"

HDR_HISTOGRAM_C_VERSION = "0.11.2" # October 12th, 2020
HDR_HISTOGRAM_C_SHA = "637f28b5f64de2e268131e4e34e6eef0b91cf5ff99167db447d9b2825eae6bad"
Expand Down
4 changes: 3 additions & 1 deletion source/adaptive_load/adaptive_load_client_main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ namespace {
*/
void WriteFileOrThrow(Envoy::Filesystem::Instance& filesystem, absl::string_view path,
absl::string_view contents) {
Envoy::Filesystem::FilePtr file = filesystem.createFile(std::string(path));
Envoy::Filesystem::FilePathAndType file_path_and_type(Envoy::Filesystem::DestinationType::File,
path);
Envoy::Filesystem::FilePtr file = filesystem.createFile(file_path_and_type);
const Envoy::Api::IoCallBoolResult open_result =
file->open(((1 << Envoy::Filesystem::File::Operation::Write)) |
(1 << (Envoy::Filesystem::File::Operation::Create)));
Expand Down
5 changes: 4 additions & 1 deletion source/client/stream_decoder.cc
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,8 @@ void StreamDecoder::onPoolReady(Envoy::Http::RequestEncoder& encoder,
}
}

// TODO(https://github.com/envoyproxy/nighthawk/issues/139): duplicated from the envoy code base.
// TODO(https://github.com/envoyproxy/nighthawk/issues/139): duplicated from
// envoy/source/common/router/router.cc
Envoy::StreamInfo::ResponseFlag
StreamDecoder::streamResetReasonToResponseFlag(Envoy::Http::StreamResetReason reset_reason) {
switch (reset_reason) {
Expand All @@ -156,6 +157,8 @@ StreamDecoder::streamResetReasonToResponseFlag(Envoy::Http::StreamResetReason re
case Envoy::Http::StreamResetReason::RemoteReset:
case Envoy::Http::StreamResetReason::RemoteRefusedStreamReset:
return Envoy::StreamInfo::ResponseFlag::UpstreamRemoteReset;
case Envoy::Http::StreamResetReason::ProtocolError:
return Envoy::StreamInfo::ResponseFlag::UpstreamProtocolError;
}
NOT_REACHED_GCOVR_EXCL_LINE;
}
Expand Down
4 changes: 3 additions & 1 deletion test/process_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,9 @@ TEST_P(ProcessTestWithSimTime, ScheduleAheadWorks) {
ASSERT_EQ(output.results_size(), 1);
EXPECT_EQ(Envoy::ProtobufUtil::TimeUtil::TimestampToNanoseconds(
output.results()[0].execution_start()),
options_->scheduled_start().value().time_since_epoch().count());
std::chrono::duration_cast<std::chrono::nanoseconds>(
options_->scheduled_start().value().time_since_epoch())
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ugh :/ this must have been annoying to figure out.. is this clang vs gcc?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one actually wasn't too bad! Reading chrono duration documentation wasn't super fun though.

I assume this is clang vs gcc or something like that? Honestly, I didn't figure this out. It was broken on my computer but not in docker, so it's something like that, but I didn't investigate what the actual difference was... sorry.

.count());
});
}
}
Expand Down
7 changes: 7 additions & 0 deletions test/request_source/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,13 @@ licenses(["notice"]) # Apache 2

envoy_package()

filegroup(
name = "testdata",
srcs = [
"test_data/test-config.yaml",
],
)

envoy_cc_test_library(
name = "stub_plugin_impl",
srcs = [
Expand Down
3 changes: 1 addition & 2 deletions test/service_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,7 @@ TEST_P(ServiceTest, InvalidRps) {
auto options = request_.mutable_start_request()->mutable_options();
options->mutable_requests_per_second()->set_value(0);
// We do not expect output, because the options proto is not valid, and can't be echoed back.
runWithFailingValidationExpectations(
false, "CommandLineOptionsValidationError.RequestsPerSecond: [\"value must be inside range");
runWithFailingValidationExpectations(false, "value must be inside range");
}

// We didn't implement updates yet, ensure we indicate so.
Expand Down
2 changes: 1 addition & 1 deletion tools/check_format.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ set -e
TO_CHECK="${2:-$PWD}"
# TODO(https://github.com/envoyproxy/nighthawk/issues/165): fully excluding everything
# from the build fixer isn't ideal.
bazel run @envoy//tools:code_format/check_format.py -- \
bazel run @envoy//tools/code_format:check_format.py -- \
--skip_envoy_build_rule_check --namespace_check Nighthawk \
--build_fixer_check_excluded_paths=$(realpath ".") \
--include_dir_order envoy,nighthawk,external/source/envoy,external,api,common,source,exe,server,client,distributor,sink,grpcpp,request_source,test_common,test \
Expand Down