Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
12ab2bc
Update edot_sdk_settings.ts
jackshirazi Aug 14, 2025
7c98de3
Update index.test.ts.snap
jackshirazi Aug 14, 2025
5a5de44
Update index.test.ts
jackshirazi Aug 14, 2025
ac42d8f
[CI] Auto-commit changed files from 'node scripts/eslint_all_files --…
kibanamachine Aug 14, 2025
a4acea1
Update edot_sdk_settings.ts
jackshirazi Aug 14, 2025
73aaf83
[CI] Auto-commit changed files from 'node scripts/eslint_all_files --…
kibanamachine Aug 14, 2025
cc2ddaf
Update edot_sdk_settings.ts
jackshirazi Aug 14, 2025
349427b
add sampling_rate
jackshirazi Aug 18, 2025
57ccc8c
add sampling_rate
jackshirazi Aug 18, 2025
f3c6967
Update edot_sdk_settings.ts
jackshirazi Aug 18, 2025
c7d915f
add sampling_rate
jackshirazi Aug 18, 2025
042fa30
Merge branch 'main' into polling_and_sampling
jackshirazi Aug 18, 2025
4e30512
[CI] Auto-commit changed files from 'node scripts/eslint_all_files --…
kibanamachine Aug 18, 2025
c4167d7
Update index.ts
jackshirazi Aug 18, 2025
7d78eb5
Merge branch 'main' into polling_and_sampling
jackshirazi Aug 18, 2025
094de78
Update x-pack/solutions/observability/plugins/apm/common/agent_config…
jackshirazi Aug 19, 2025
3a75263
Update x-pack/solutions/observability/plugins/apm/common/agent_config…
jackshirazi Aug 19, 2025
993696e
Merge branch 'main' into polling_and_sampling
jackshirazi Aug 19, 2025
7c75d02
Update x-pack/solutions/observability/plugins/apm/common/agent_config…
jackshirazi Aug 19, 2025
e103280
Merge branch 'main' into polling_and_sampling
jackshirazi Aug 19, 2025
ec68a8c
Merge branch 'main' into polling_and_sampling
elasticmachine Aug 21, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,36 @@ export const edotSDKSettings: RawSettingDefinition[] = [
'opentelemetry/dotnet/elastic',
],
},
{
key: 'opamp_polling_interval',
type: 'duration',
defaultValue: '30s',
min: '1s',
label: i18n.translate('xpack.apm.agentConfig.pollingInterval.label', {
defaultMessage: 'OpAMP HTTP polling interval',
}),
description: i18n.translate('xpack.apm.agentConfig.pollingInterval.description', {
defaultMessage:
'The default interval between checking the collector for new changes to config.\n' +
'Note the interval is automatically exponentially extended on failures then reset to the value specified here, on recovery.',
}),
includeAgents: ['opentelemetry/java/elastic'],
},
{
key: 'sampling_rate',
type: 'float',
defaultValue: '1.0',
label: i18n.translate('xpack.apm.agentConfig.samplingRate.label', {
defaultMessage: 'Sampling rate',
}),
description: i18n.translate('xpack.apm.agentConfig.samplingRate.description', {
defaultMessage:
'By default, the agent will sample every span in every trace (e.g. request to your service). ' +
'To reduce overhead and storage requirements, you can set the sampling rate to a value between 0.0 and 1.0. ' +
Comment thread
xrmx marked this conversation as resolved.
'Further details can be found in the [OpenTelemetry Sampling Concepts](https://opentelemetry.io/docs/concepts/sampling/) page.',
}),
includeAgents: ['opentelemetry/java/elastic', 'opentelemetry/python/elastic'],
},
{
key: 'send_traces',
type: 'boolean',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,8 @@ describe('filterByAgent', () => {
'deactivate_all_instrumentations',
'deactivate_instrumentations',
'logging_level',
'opamp_polling_interval',
'sampling_rate',
'send_logs',
'send_metrics',
'send_traces',
Expand All @@ -210,7 +212,7 @@ describe('filterByAgent', () => {

it('opentelemetry/python/elastic', () => {
expect(getSettingKeysForAgent('opentelemetry/python/elastic')).toEqual(
expect.arrayContaining(['logging_level'])
expect.arrayContaining(['logging_level', 'sampling_rate'])
);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function getSettingDefaults(setting: RawSettingDefinition): SettingDefinition {
}

case 'float': {
if (setting.key === 'transaction_sample_rate') {
if (setting.key === 'transaction_sample_rate' || setting.key === 'sampling_rate') {
return {
validation: floatFourDecimalPlacesRt,
...setting,
Expand Down