Skip to content

Commit 010fe71

Browse files
authored
Merge branch 'envoyproxy:main' into nighthawk-connect-support
2 parents 75cbb87 + 157a1e1 commit 010fe71

20 files changed

+368
-206
lines changed

.bazelrc

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,7 @@ build:asan --linkopt='-L/opt/llvm/lib/clang/18/lib/x86_64-unknown-linux-gnu'
192192
build:macos --action_env=PATH=/opt/homebrew/bin:/opt/local/bin:/usr/local/bin:/usr/bin:/bin
193193
build:macos --host_action_env=PATH=/opt/homebrew/bin:/opt/local/bin:/usr/local/bin:/usr/bin:/bin
194194
build:macos --define tcmalloc=disabled
195+
build:macos --cxxopt=-Wno-nullability-completeness
195196

196197
# macOS ASAN/UBSAN
197198
build:macos-asan --config=asan
@@ -293,7 +294,7 @@ build:fuzz-coverage --test_tag_filters=-nocoverage
293294
# resources required to build and run the tests.
294295
build:fuzz-coverage --define=wasm=disabled
295296
build:fuzz-coverage --config=fuzz-coverage-config
296-
build:fuzz-coverage-config --//tools/coverage:config=//test:fuzz_coverage_config
297+
build:fuzz-coverage-config --//tools/coverage:config=@envoy//test:fuzz_coverage_config
297298

298299
build:cache-local --remote_cache=grpc://localhost:9092
299300

@@ -397,7 +398,7 @@ build:compile-time-options --@envoy//source/extensions/filters/http/kill_request
397398

398399
# Docker sandbox
399400
# NOTE: Update this from https://github.com/envoyproxy/envoy-build-tools/blob/main/toolchains/rbe_toolchains_config.bzl#L8
400-
build:docker-sandbox --experimental_docker_image=envoyproxy/envoy-build-ubuntu:f4a881a1205e8e6db1a57162faf3df7aed88eae8@sha256:b10346fe2eee41733dbab0e02322c47a538bf3938d093a5daebad9699860b814
401+
build:docker-sandbox --experimental_docker_image=docker.io/envoyproxy/envoy-build-ubuntu:f4a881a1205e8e6db1a57162faf3df7aed88eae8@sha256:b10346fe2eee41733dbab0e02322c47a538bf3938d093a5daebad9699860b814
401402
build:docker-sandbox --spawn_strategy=docker
402403
build:docker-sandbox --strategy=Javac=docker
403404
build:docker-sandbox --strategy=Closure=docker
@@ -581,8 +582,10 @@ common:remote-envoy-engflow --config=rbe-envoy-engflow
581582
common:remote-cache-envoy-engflow --config=common-envoy-engflow
582583
common:remote-cache-envoy-engflow --config=cache-envoy-engflow
583584

585+
common:cves --//tools/dependency:cve-data=//tools/dependency:cve-data-dir
586+
584587
# Specifies the rustfmt.toml for all rustfmt_test targets.
585-
build --@rules_rust//rust/settings:rustfmt.toml=//:rustfmt.toml
588+
build --@rules_rust//rust/settings:rustfmt.toml=@envoy//:rustfmt.toml
586589

587590
#############################################################################
588591
# debug: Various Bazel debugging flags

.bazelversion

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
7.6.0
1+
7.6.1

.github/workflows/scorecard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,6 @@ jobs:
4040
retention-days: 5
4141

4242
- name: "Upload to code-scanning"
43-
uses: github/codeql-action/upload-sarif@f1f6e5f6af878fb37288ce1c627459e94dbf7d01 # v3.29.5
43+
uses: github/codeql-action/upload-sarif@f443b600d91635bebf5b0d9ebc620189c0d6fba5 # v3.29.5
4444
with:
4545
sarif_file: results.sarif

MAINTAINERS.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ You can customize the script's behavior using the following arguments:
5858
* `--branch_name NAME`: The name of the branch to create in the Nighthawk
5959
repository for the update. Default: `update-envoy-YYYYMMDD` (e.g.,
6060
`update-envoy-20250809`)
61+
* `--agent_invocation CMD`: Command to invoke an LLM agent (e.g., `gemini`) to
62+
attempt to automatically fix errors. The agent will be called with the
63+
prompt provided via stdin. Default: `None`
6164

6265
The script provides detailed output for each step it performs, prefixed with
6366
`NighthawkEnvoyUpdate:` or `....EnvoyCommitIntegration:` for sub-steps.
@@ -72,6 +75,21 @@ manual step (like resolving merge conflicts):
7275
The script will detect the existing branch, rebase it on `origin/main` if
7376
necessary, and attempt to continue the update process.
7477

78+
### LLM-in-the-loop automated integration fix
79+
80+
To experimentaly enable automated fixes, you can use the `--agent_invocation`
81+
argument. The utility will use the specified command (e.g. `gemini`) when a step
82+
fails and pass a detailed prompt via stdin. The agent can then attempt to modify
83+
the files in your local Nighthawk repository to resolve the issue. The utility
84+
gives the agent 3 tries to fix an error before returning the error to the user.
85+
86+
```bash
87+
./tools/nighthawk_envoy_updater.py \
88+
--nighthawk_dir ~/my_local_nighthawk_git_repo \
89+
--branch_name my-envoy-update-with-agent \
90+
--agent_invocation gemini
91+
```
92+
7593
### Outcomes
7694

7795
* **Initial checks fail:** A script prerequisite is violated, like the

bazel/repositories.bzl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
22

3-
ENVOY_COMMIT = "db557abb8afd8a4e91d3895979569ade35372de3"
4-
ENVOY_SHA = "8573a96a4883d24db35c7528637389fe6406a875b3593382af98d91718dc20e5"
3+
ENVOY_COMMIT = "405bf36c1ddd174f9c9dbc46766a455a29416dbd"
4+
ENVOY_SHA = "c62b45d821e172010e1ab20bdb86afb5c5561b0938c16259fe97398739895e3d"
55

66
HDR_HISTOGRAM_C_VERSION = "0.11.8" # June 18th, 2025
77
HDR_HISTOGRAM_C_SHA = "bb95351a6a8b242dc9be1f28562761a84d4cf0a874ffc90a9b630770a6468e94"

ci/do_ci.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,14 @@ function do_check_format() {
255255
./tools/format_python_tools.sh check
256256
}
257257

258+
function do_build_nighthawk_image() {
259+
echo "Building docker images"
260+
do_opt_build
261+
262+
echo "do_docker: Running ci/docker/docker_build.sh."
263+
./ci/docker/docker_build.sh
264+
}
265+
258266
function do_docker() {
259267
echo "docker..."
260268
cd "${SRCDIR}"
@@ -368,6 +376,11 @@ case "$1" in
368376
do_opt_build
369377
exit 0
370378
;;
379+
build_nighthawk_image)
380+
setup_clang_toolchain
381+
do_build_nighthawk_image
382+
exit 0
383+
;;
371384
*)
372385
echo "must be one of [opt_build,build,test,clang_tidy,coverage,coverage_integration,asan,tsan,benchmark_with_own_binaries,docker,check_format,fix_format,test_gcc]"
373386
exit 1

ci/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
x-envoy-build-base: &envoy-build-base
22
image: >-
3-
${ENVOY_BUILD_IMAGE:-envoyproxy/envoy-build-ubuntu:f4a881a1205e8e6db1a57162faf3df7aed88eae8@sha256:b10346fe2eee41733dbab0e02322c47a538bf3938d093a5daebad9699860b814}
3+
${ENVOY_BUILD_IMAGE:-docker.io/envoyproxy/envoy-build-ubuntu:f4a881a1205e8e6db1a57162faf3df7aed88eae8@sha256:b10346fe2eee41733dbab0e02322c47a538bf3938d093a5daebad9699860b814}
44
user: root:root
55
working_dir: ${ENVOY_DOCKER_SOURCE_DIR:-/source}
66
stdin_open: true

ci/docker/Dockerfile-nighthawk

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
FROM ubuntu:24.04@sha256:1e622c5f073b4f6bfad6632f2616c7f59ef256e96fe78bf6a595d1dc4376ac02
22

3-
RUN apt-get update && apt-get install libatomic1
3+
RUN apt -y update && apt -y install libatomic1 curl
44

55
ADD nighthawk_client /usr/local/bin/nighthawk_client
66
ADD nighthawk_test_server /usr/local/bin/nighthawk_test_server
77
ADD nighthawk_output_transform /usr/local/bin/nighthawk_output_transform
88
ADD nighthawk_service /usr/local/bin/nighthawk_service
99
ADD nighthawk_adaptive_load_client /usr/local/bin/nighthawk_adaptive_load_client
10-
ADD default-config.yaml /etc/envoy/envoy.yaml
10+
11+
ADD default-config.yaml /etc/nighthawk/nighthawk.yaml
1112

1213
# Ports for nighthawk_test_server, see default-config.yaml
13-
EXPOSE 10001
14-
EXPOSE 10080
14+
EXPOSE 10001 10080
1515
# The default port for nighthawk_service
1616
EXPOSE 8443
1717

18-
CMD ["-c", "/etc/envoy/envoy.yaml"]
18+
ENTRYPOINT ["/usr/local/bin/nighthawk_test_server"]
19+
CMD ["-c", "/etc/nighthawk/nighthawk.yaml"]

ci/docker/default-config.yaml

Lines changed: 37 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,40 @@ admin:
55
socket_address: { address: 0.0.0.0, port_value: 10001 }
66
static_resources:
77
listeners:
8-
- address:
9-
socket_address:
10-
address: 0.0.0.0
11-
port_value: 10080
12-
filter_chains:
13-
- filters:
14-
- name: envoy.http_connection_manager
15-
config:
16-
generate_request_id: false
17-
codec_type: auto
18-
stat_prefix: ingress_http
19-
route_config:
20-
name: local_route
21-
virtual_hosts:
22-
- name: service
23-
domains:
24-
- "*"
25-
http_filters:
26-
- name: time-tracking
27-
- name: dynamic-delay
28-
- name: test-server
29-
config:
30-
response_body_size: 10
31-
v3_response_headers:
32-
- { header: { key: "x-nh", value: "1"}}
33-
- name: envoy.router
34-
config:
35-
dynamic_stats: false
8+
- address:
9+
socket_address:
10+
address: 0.0.0.0
11+
port_value: 10080
12+
filter_chains:
13+
- filters:
14+
- name: envoy.filters.network.http_connection_manager
15+
typed_config:
16+
"@type": type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager
17+
generate_request_id: false
18+
codec_type: AUTO
19+
stat_prefix: ingress_http
20+
route_config:
21+
name: local_route
22+
virtual_hosts:
23+
- name: service
24+
domains:
25+
- "*"
26+
http_filters:
27+
- name: time-tracking
28+
typed_config:
29+
"@type": type.googleapis.com/nighthawk.server.TimeTrackingConfiguration
30+
emit_previous_request_delta_in_response_header: x-origin-request-receipt-delta
31+
- name: dynamic-delay
32+
typed_config:
33+
"@type": type.googleapis.com/nighthawk.server.DynamicDelayConfiguration
34+
static_delay: 0s
35+
- name: test-server # before envoy.router because order matters!
36+
typed_config:
37+
"@type": type.googleapis.com/nighthawk.server.ResponseOptions
38+
response_body_size: 10
39+
v3_response_headers:
40+
- { header: { key: "x-nh", value: "1" } }
41+
- name: envoy.filters.http.router
42+
typed_config:
43+
"@type": type.googleapis.com/envoy.extensions.filters.http.router.v3.Router
44+
dynamic_stats: false

ci/docker/docker_build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ set -e
1010
# publishing sensitive information into public CI logs if someone makes a change in a
1111
# consuming script that is off guard.
1212

13-
DOCKER_NAME="nighthawk"
14-
DOCKER_IMAGE_PREFIX="envoyproxy/${DOCKER_NAME}"
13+
DOCKER_IMAGE_PREFIX="${DOCKER_IMAGE_PREFIX:-envoyproxy/nighthawk}"
14+
1515
BINARIES=(nighthawk_test_server nighthawk_client nighthawk_service nighthawk_output_transform nighthawk_adaptive_load_client)
1616
BAZEL_BIN="$(bazel info -c opt bazel-bin)"
1717
WORKSPACE="$(bazel info workspace)"
@@ -33,6 +33,6 @@ done
3333

3434
cd "${TMP_DIR}"
3535
echo "running docker build ... "
36-
docker build -f "${TMP_DIR}/Dockerfile-${DOCKER_NAME}" -t "${DOCKER_IMAGE_PREFIX}-dev:latest" .
36+
docker build -f "${TMP_DIR}/Dockerfile-nighthawk" -t "${DOCKER_IMAGE_PREFIX}-dev:latest" .
3737
rm -rf "${TMP_DIR}"
3838
echo "docker build finished"

0 commit comments

Comments
 (0)