Skip to content

Commit dae5576

Browse files
authored
ci: Configurable TBS sampling rate for benchmarks (elastic#17250)
CI benchmarks: make TBS sampling rate configurable, for both standalone and ECH. Misc fixes.
1 parent c3e28e2 commit dae5576

22 files changed

+71
-16
lines changed

.github/workflows/benchmarks.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,18 @@ on:
2020
required: false
2121
type: string
2222
default: "10GB"
23+
tailSamplingSampleRate:
24+
description: 'Blanket sample rate used by tail-based sampling'
25+
required: false
26+
type: string
27+
default: "0.1"
2328
profile:
2429
description: 'System profile for benchmark, e.g. system-profiles/8GBx1zone.tfvars'
2530
required: false
2631
type: string
2732
# defaults set below (TFVARS_SOURCE)
2833
runOnStable:
29-
description: 'Benchmark on latest stable version instead of SNAPSHOT'
34+
description: 'Benchmark on latest stable version instead of a build from commit'
3035
required: false
3136
type: boolean
3237
default: false
@@ -69,13 +74,18 @@ on:
6974
required: false
7075
type: string
7176
default: "10GB"
77+
tailSamplingSampleRate:
78+
description: 'Blanket sample rate used by tail-based sampling'
79+
required: false
80+
type: string
81+
default: "0.1"
7282
profile:
7383
description: 'System profile for benchmark, e.g. system-profiles/8GBx1zone.tfvars'
7484
required: false
7585
type: string
7686
# defaults set below (TFVARS_SOURCE)
7787
runOnStable:
78-
description: 'Benchmark on latest stable version instead of SNAPSHOT'
88+
description: 'Benchmark on latest stable version instead of a build from commit'
7989
required: false
8090
type: boolean
8191
default: false
@@ -128,6 +138,7 @@ jobs:
128138
TF_VAR_run_standalone: ${{ inputs.runStandalone || github.event.schedule=='0 0 1 * *' }}
129139
TF_VAR_apm_server_tail_sampling: ${{ inputs.enableTailSampling || 'false' }} # set the default again otherwise schedules won't work
130140
TF_VAR_apm_server_tail_sampling_storage_limit: ${{ inputs.tailSamplingStorageLimit || '10GB' }} # set the default again otherwise schedules won't work
141+
TF_VAR_apm_server_tail_sampling_sample_rate: ${{ inputs.tailSamplingSampleRate || '0.1' }} # set the default again otherwise schedules won't work
131142
RUN_STANDALONE: ${{ inputs.runStandalone || github.event.schedule=='0 0 1 * *' }}
132143
PGO_EXPORT: ${{ inputs.pgoExport || github.event.schedule=='0 0 1 * *' }}
133144
TFVARS_SOURCE: ${{ inputs.profile || 'system-profiles/8GBx1zone.tfvars' }} # set the default again otherwise schedules won't work

testing/benchmark/main.tf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ module "ec_deployment" {
102102
apm_server_pprof = true
103103
apm_server_tail_sampling = var.apm_server_tail_sampling
104104
apm_server_tail_sampling_storage_limit = var.apm_server_tail_sampling_storage_limit
105+
apm_server_tail_sampling_sample_rate = var.apm_server_tail_sampling_sample_rate
105106

106107
elasticsearch_size = var.elasticsearch_size
107108
elasticsearch_zone_count = var.elasticsearch_zone_count
@@ -163,6 +164,7 @@ module "standalone_apm_server" {
163164

164165
apm_server_tail_sampling = var.apm_server_tail_sampling
165166
apm_server_tail_sampling_storage_limit = var.apm_server_tail_sampling_storage_limit
167+
apm_server_tail_sampling_sample_rate = var.apm_server_tail_sampling_sample_rate
166168

167169
aws_provisioner_key_name = var.private_key
168170

testing/benchmark/system-profiles/16GBx2zone-aws.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.2xlarge"
66

77
# Elastic Cloud
8-
ess_region = "us-west-2"
8+
ess_region = "us-west-2"
99
deployment_template = "aws-cpu-optimized-faster-warm"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/16GBx2zone-azure.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.2xlarge"
66

77
# Elastic Cloud
8-
ess_region = "azure-westus2"
8+
ess_region = "azure-westus2"
99
deployment_template = "azure-cpu-optimized"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/16GBx2zone-gcp.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.2xlarge"
66

77
# Elastic Cloud
8-
ess_region = "gcp-us-west2"
8+
ess_region = "gcp-us-west2"
99
deployment_template = "gcp-cpu-optimized"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/32GBx2zone-aws.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.4xlarge"
66

77
# Elastic Cloud
8-
ess_region = "us-west-2"
8+
ess_region = "us-west-2"
99
deployment_template = "aws-cpu-optimized-faster-warm"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/32GBx2zone-azure.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.4xlarge"
66

77
# Elastic Cloud
8-
ess_region = "azure-westus2"
8+
ess_region = "azure-westus2"
99
deployment_template = "azure-cpu-optimized"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/32GBx2zone-gcp.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.4xlarge"
66

77
# Elastic Cloud
8-
ess_region = "gcp-us-west2"
8+
ess_region = "gcp-us-west2"
99
deployment_template = "gcp-cpu-optimized"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/8GBx1zone-aws.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.2xlarge"
66

77
# Elastic Cloud
8-
ess_region = "us-west-2"
8+
ess_region = "us-west-2"
99
deployment_template = "aws-cpu-optimized-faster-warm"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

testing/benchmark/system-profiles/8GBx1zone-azure.tfvars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ user_name = "USER"
55
worker_instance_type = "c6i.2xlarge"
66

77
# Elastic Cloud
8-
ess_region = "azure-westus2"
8+
ess_region = "azure-westus2"
99
deployment_template = "azure-cpu-optimized"
1010
# The number of AZs the APM Server should span.
1111
apm_server_zone_count = 1

0 commit comments

Comments
 (0)