From 563f3b54d2956ae6a66ee258af88aac104e833db Mon Sep 17 00:00:00 2001 From: "prath.shenoy" Date: Mon, 16 Nov 2026 21:47:40 +0000 Subject: [PATCH] test(stovepipe): Speed up end-to-end runs --- doc/rfc/stovepipe/steps/buildsignal.md | 2 +- service/stovepipe/README.md | 2 +- service/stovepipe/server/README.md | 6 ++++++ test/e2e/stovepipe/BUILD.bazel | 2 ++ test/e2e/stovepipe/docker-compose.e2e.yml | 8 ++++++++ test/e2e/stovepipe/stovepipe.yaml | 12 ++++++++++++ test/e2e/stovepipe/suite_test.go | 12 ++++++++++-- 7 files changed, 40 insertions(+), 4 deletions(-) create mode 100644 test/e2e/stovepipe/docker-compose.e2e.yml create mode 100644 test/e2e/stovepipe/stovepipe.yaml diff --git a/doc/rfc/stovepipe/steps/buildsignal.md b/doc/rfc/stovepipe/steps/buildsignal.md index 7e8aab897..70b12adc5 100644 --- a/doc/rfc/stovepipe/steps/buildsignal.md +++ b/doc/rfc/stovepipe/steps/buildsignal.md @@ -118,7 +118,7 @@ Two-tier cadence, matching SubmitQueue: | `accepted` | `BuildSignal.AcceptedPollDelayMs` (default 5000ms) | Queued by the runner, not started — poll infrequently. | | `running` | `BuildSignal.RunningPollDelayMs` (default 2000ms) | Actively executing — poll more often. | -Each delivery resolves these settings through the queue configuration store. Hosts apply a service baseline, deployment-wide settings, and per-queue overrides before supplying immutable configurations. The reference server embeds its baseline YAML and layers an optional configuration file over it. See the [configuration guide](../../../../service/stovepipe/server/README.md). +Each delivery resolves these settings through the queue configuration store. Hosts apply a service baseline, deployment-wide settings, and per-queue overrides before supplying immutable configurations. The reference server embeds its baseline YAML and layers an optional configuration file over it; the e2e profile selects shorter positive waits without changing consumer retry behavior. See the [configuration guide](../../../../service/stovepipe/server/README.md). ## Error classification diff --git a/service/stovepipe/README.md b/service/stovepipe/README.md index 546dc3655..e908c0d36 100644 --- a/service/stovepipe/README.md +++ b/service/stovepipe/README.md @@ -55,7 +55,7 @@ The Stovepipe controllers live under [`stovepipe/controller/`](../../stovepipe/c ## Queue and stage configuration -The server accepts an optional `-config` YAML file for deployment-wide queue and stage settings and per-queue overrides. See the [configuration guide](server/README.md) for settings, validation. The service always loads its embedded baseline; the optional file overrides it. +The server accepts an optional `-config` YAML file for deployment-wide queue and stage settings and per-queue overrides. See the [configuration guide](server/README.md) for settings, validation, and the isolated end-to-end profile. The service always loads its embedded baseline; the optional file overrides it. ## Running diff --git a/service/stovepipe/server/README.md b/service/stovepipe/server/README.md index 0dbfdd8ef..b931028ec 100644 --- a/service/stovepipe/server/README.md +++ b/service/stovepipe/server/README.md @@ -15,3 +15,9 @@ Deployment-wide stage settings from the optional file override the service basel Every queue override must name a queue in `MQ_TENANTS`; queues without overrides inherit the deployment configuration. Queue registration is separate from stage settings. The static store only serves registered queues. The baseline retains a concurrency limit of one, a five-second admission wait, five-second accepted-build polling, two-second running-build polling, two-minute build analysis polling, and thirty-second issue refresh and recovery waits. These values are defined only in the baseline YAML. + +## End-to-end profile + +The Stovepipe e2e suite stages its own override file and selects it through a Compose overlay. All periodic stage waits and the admission wait become 250 milliseconds; unspecified settings, including concurrency, inherit the service baseline. Immediate batch continuation and consumer retry policies are unchanged. Ordinary local Compose runs do not select the e2e profile. + +Run the real-stack suite locally with `bazel test //test/e2e/stovepipe:go_default_test --nocache_test_results`. Bazel supplies the server binary, Compose overlay, and override file through declared inputs; the baseline is embedded in the binary. The runner timeout remains the existing safety ceiling rather than the normal runtime target. diff --git a/test/e2e/stovepipe/BUILD.bazel b/test/e2e/stovepipe/BUILD.bazel index 3c50b0508..4088bd513 100644 --- a/test/e2e/stovepipe/BUILD.bazel +++ b/test/e2e/stovepipe/BUILD.bazel @@ -16,6 +16,8 @@ go_test( "suite_test.go", ], data = [ + "docker-compose.e2e.yml", + "stovepipe.yaml", "//platform/extension/counter/mysql/schema", "//platform/extension/messagequeue/mysql/schema", "//service/stovepipe:docker-compose.yml", diff --git a/test/e2e/stovepipe/docker-compose.e2e.yml b/test/e2e/stovepipe/docker-compose.e2e.yml new file mode 100644 index 000000000..6f107e3f0 --- /dev/null +++ b/test/e2e/stovepipe/docker-compose.e2e.yml @@ -0,0 +1,8 @@ +services: + stovepipe-service: + command: ["./stovepipe", "-config", "/etc/stovepipe/config.yaml"] + volumes: + - type: bind + source: ${REPO_ROOT}/test/e2e/stovepipe/stovepipe.yaml + target: /etc/stovepipe/config.yaml + read_only: true diff --git a/test/e2e/stovepipe/stovepipe.yaml b/test/e2e/stovepipe/stovepipe.yaml new file mode 100644 index 000000000..76a826b0f --- /dev/null +++ b/test/e2e/stovepipe/stovepipe.yaml @@ -0,0 +1,12 @@ +queueconfig: + stages: + process: + gateWaitDelay: 250ms + buildSignal: + acceptedPollDelay: 250ms + runningPollDelay: 250ms + buildAnalysis: + pollDelay: 250ms + issueTrack: + refreshDelay: 250ms + recoveryWaitDelay: 250ms diff --git a/test/e2e/stovepipe/suite_test.go b/test/e2e/stovepipe/suite_test.go index 09f8aa8bc..8ccee5c01 100644 --- a/test/e2e/stovepipe/suite_test.go +++ b/test/e2e/stovepipe/suite_test.go @@ -71,11 +71,19 @@ func (s *StovepipeE2ESuite) SetupSuite() { s.log.Logf("Starting Stovepipe e2e test suite using docker-compose") composeFile := testutil.Runfile("service/stovepipe/docker-compose.yml") - s.stack = testutil.NewComposeStack(t, s.log, s.ctx, composeFile, "e2e-stovepipe", + s.stack = testutil.NewComposeStack( + t, + s.log, + s.ctx, + composeFile, + "e2e-stovepipe", + testutil.WithOverlay(testutil.Runfile("test/e2e/stovepipe/docker-compose.e2e.yml")), testutil.WithBuildContext(map[string]string{ + "test/e2e/stovepipe/stovepipe.yaml": "test/e2e/stovepipe/stovepipe.yaml", ".docker-bin/stovepipe": "service/stovepipe/server/stovepipe_linux", "service/stovepipe/server/Dockerfile": "service/stovepipe/server/Dockerfile", - })) + }), + ) err := s.stack.Up("mysql-app", "mysql-queue") require.NoError(t, err, "failed to start compose stack")