Add multiple service deployer to benchmarks#3304
Conversation
- Mask secrets in reports. - Add test integration
|
The CI error Here's the full error: The other CI errors are unrelated to this change. They are failing to bring up the Elastic Stack due to Client Timeout. Re-triggered the step in hopes of getting it fixed. |
@kcreddy This errors is because this new field requires to be added in the package spec for the benchmark system configuration here in this file: Could you create a PR to include that? That would imply that this would need a new package-spec release to include this field here. |
@mrodm, added here - elastic/package-spec#1099 into |
In order to run CI successfully , yes, I think so. It could be tested and worked locally until that happens, but this PR to add support for multi-deployer in system benchmarks will require a new package-spec release to include your change. |
Adds a benchmark test package that exercises both the `docker` and `tf` service deployers in the system benchmark runner within a single package: - `httpjson` data stream: `deployer: docker` — runs a mock HTTP server (stream image) serving generated JSON events, collected via httpjson input. - `logfile` data stream: `deployer: tf` — uses the Terraform `local` provider to write a sample log file, collected via filestream input. No cloud credentials required, making it safe to run in standard CI.
|
@mrodm, the CI is failing on tests unrelated to this change: Can you please review the PR? |
...ystem_benchmark_crowdstrike/data_stream/falcon/_dev/benchmark/pipeline/test-event-stream.log
Outdated
Show resolved
Hide resolved
.../packages/benchmarks/system_benchmark_crowdstrike/_dev/benchmark/system/falcon-benchmark.yml
Show resolved
Hide resolved
...rks/system_benchmark_crowdstrike/data_stream/falcon/_dev/test/pipeline/test-event-stream.log
Outdated
Show resolved
Hide resolved
.../packages/benchmarks/system_benchmark_crowdstrike/_dev/benchmark/system/falcon-benchmark.yml
Show resolved
Hide resolved
|
|
||
| func newReport(benchName, corporaFile string, s *scenario, sum *metricsSummary) *report { | ||
| func newReport(benchName, corporaFile string, s *scenario, sum *metricsSummary, secretVarNames map[string]bool) *report { | ||
| var report report |
There was a problem hiding this comment.
Would it be interesting or worthy to add the deployer used to run the benchmark in the report too ?
It could be kept as it is the report if it is not needed.
There was a problem hiding this comment.
Done in 6210301
╭─────────────────────────────────────────────────────────────────────────────────────╮
│ parameters │
├──────────────────────────────────────────┬──────────────────────────────────────────┤
│ package version │ 3.12.0 │
+ │ deployer │ docker │
│ input │ cel │
│ vars.client_id │ xxxx │
│ vars.client_secret │ xxxx │
│ vars.token_url │ http://svc-crowdstrike:8080/oauth2/token │
│ vars.url │ http://svc-crowdstrike:8080 │
│ data_stream.name │ alert │
│ data_stream.vars.enable_request_tracer │ true │
│ data_stream.vars.preserve_original_event │ true │
│ warmup time period │ 2s │
│ benchmark time period │ 0s │
│ wait for data timeout │ 10m0s │
│ corpora.generator.total_events │ 1000 │
│ corpora.generator.template.path │ ./alert-benchmark/template.ndjson │
│ corpora.generator.template.raw │ │
│ corpora.generator.template.type │ gotext │
│ corpora.generator.config.path │ ./alert-benchmark/config.yml │
│ corpora.generator.config.raw │ map[] │
│ corpora.generator.fields.path │ ./alert-benchmark/fields.yml │
│ corpora.generator.fields.raw │ map[] │
│ corpora.input_service.name │ crowdstrike │
│ corpora.input_service.signal │ │
╰──────────────────────────────────────────┴──────────────────────────────────────────╯There was a problem hiding this comment.
This works in those packages that define multiple deployers, but in the ones that just use the only deployer defined, that field is shown as empty:
https://buildkite.com/elastic/elastic-package/builds/7576#019d29de-e5d8-49c8-9f5f-94b89e96ce1f/L1092
╭─────────────────────────────────────────────────────────────────╮
│ parameters │
├─────────────────────────────────┬───────────────────────────────┤
│ package version │ 999.999.999 │
│ deployer │ │
│ input │ filestream │
mrodm
left a comment
There was a problem hiding this comment.
Just a minor change to show the deployer value in those packages that use the only deployer defined in the package.
|
|
||
| func newReport(benchName, corporaFile string, s *scenario, sum *metricsSummary) *report { | ||
| func newReport(benchName, corporaFile string, s *scenario, sum *metricsSummary, secretVarNames map[string]bool) *report { | ||
| var report report |
There was a problem hiding this comment.
This works in those packages that define multiple deployers, but in the ones that just use the only deployer defined, that field is shown as empty:
https://buildkite.com/elastic/elastic-package/builds/7576#019d29de-e5d8-49c8-9f5f-94b89e96ce1f/L1092
╭─────────────────────────────────────────────────────────────────╮
│ parameters │
├─────────────────────────────────┬───────────────────────────────┤
│ package version │ 999.999.999 │
│ deployer │ │
│ input │ filestream │
Resolves empty deployer field in benchmark reports for packages with a single deployer that don't explicitly specify it in the scenario config.
Fixed in cab532b I tested out ╭────────────────────────────────────────────────────────────────────────────────────────╮
│ parameters │
├──────────────────────────────────────────┬─────────────────────────────────────────────┤
│ package version │ 3.6.0 │
+ │ deployer │ docker │
│ input │ cel │
│ vars.auth_key │ xxxx │
│ vars.enable_request_tracer │ true │
│ data_stream.name │ malware │
|
|
/test |
💛 Build succeeded, but was flaky
Failed CI StepsHistory
cc @kcreddy |
Closes #3266