Skip to content

Support multiple sample events#1423

Draft
jsoriano wants to merge 8 commits into
elastic:mainfrom
jsoriano:multiple-sample-events
Draft

Support multiple sample events#1423
jsoriano wants to merge 8 commits into
elastic:mainfrom
jsoriano:multiple-sample-events

Conversation

@jsoriano
Copy link
Copy Markdown
Member

@jsoriano jsoriano commented Aug 30, 2023

Add a new samples setting to the system test configuration files, that can be optionally used to select specific documents for the collected sample files.

For example, to select a document that contains the 200 status code:

samples:
  - name: "200"
    condition:
      key: "http.response.status_code"
      value: "200"

When these samples are defined, the default sample_event.json is not collected. Instead, one document is collected for each defined sample, called sample_event_<name>.json, where <name> is the name in the config.

When multiple events are collected, all of them are rendered in the README when event is used.

A change is required in package-spec to support the multiple sample files.

Closes #773

@jsoriano jsoriano requested a review from a team August 30, 2023 22:09
@jsoriano jsoriano self-assigned this Aug 30, 2023
@jsoriano jsoriano force-pushed the multiple-sample-events branch from 739c861 to 14d25c0 Compare August 31, 2023 10:16
Comment thread internal/testrunner/runners/system/runner.go Outdated
@elasticmachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

History

cc @jsoriano

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support multiple sample events

3 participants