Skip to content

Enforce single config for APM agent service/env in API #57018

@graphaelli

Description

@graphaelli

Kibana version: 7.x

Describe the bug: Multiple configurations for the same service/environment in APM agent configuration can be created.

Steps to reproduce:

  1. curl 'http://admin:XXX@localhost:5601/api/apm/settings/agent-configuration/new' -H 'Accept: */*' -H 'kbn-version: 7.6.0' -H 'Content-Type: application/json' --data '{"service":{},"settings":{"transaction_sample_rate":1,"capture_body":"off","transaction_max_spans":500}}'
  2. curl 'http://admin:XXX@localhost:5601/api/apm/settings/agent-configuration/new' -H 'Accept: */*' -H 'kbn-version: 7.6.0' -H 'Content-Type: application/json' --data '{"service":{},"settings":{"transaction_sample_rate":1,"capture_body":"off","transaction_max_spans":500}}'

Expected behavior:

2nd call should fail.

Screenshots (if relevant):

image

related to #57005

Metadata

Metadata

Assignees

Labels

Team:APM - DEPRECATEDUse Team:obs-ux-infra_services.bugFixes for quality problems that affect the customer experience

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions