Skip to content

Commit 68c693d

Browse files
authored
Revert "feat: Emit breakdowns for all transactions (#25886)" (#26082)
This reverts commit eb22065.
1 parent fc9e068 commit 68c693d

File tree

8 files changed

+19
-40
lines changed

8 files changed

+19
-40
lines changed

src/sentry/projectoptions/defaults.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
epoch_defaults={
7171
1: {
7272
"span_ops": {
73-
"type": "spanOperations",
73+
"type": "span_operations",
7474
"matches": ["http", "db", "browser", "resource"],
7575
}
7676
},

src/sentry/relay/config.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -162,9 +162,10 @@ def get_project_config(project, full_config=True, project_keys=None):
162162
if dynamic_sampling is not None:
163163
cfg["config"]["dynamicSampling"] = dynamic_sampling
164164

165-
breakdowns_config = project.get_option("sentry:breakdowns")
166-
if breakdowns_config is not None:
167-
cfg["config"]["breakdowns"] = breakdowns_config
165+
if features.has("organizations:performance-ops-breakdown", project.organization):
166+
breakdowns_config = project.get_option("sentry:breakdowns")
167+
if breakdowns_config is not None:
168+
cfg["config"]["breakdowns"] = breakdowns_config
168169

169170
if not full_config:
170171
# This is all we need for external Relay processors

tests/sentry/api/endpoints/test_relay_projectconfigs.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,10 @@
1616

1717

1818
def _get_all_keys(config):
19-
for config_key in config:
20-
yield config_key
21-
if isinstance(config[config_key], dict):
22-
for key in _get_all_keys(config[config_key]):
23-
# Bypass operations breakdown key
24-
if config_key == "breakdowns" and key == "span_ops":
25-
continue
19+
for key in config:
20+
yield key
21+
if isinstance(config[key], dict):
22+
for key in _get_all_keys(config[key]):
2623
yield key
2724

2825

tests/sentry/api/endpoints/test_relay_projectconfigs_v2.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,10 @@
1616

1717

1818
def _get_all_keys(config):
19-
for config_key in config:
20-
yield config_key
21-
if isinstance(config[config_key], dict):
22-
for key in _get_all_keys(config[config_key]):
23-
# Bypass operations breakdown key
24-
if config_key == "breakdowns" and key == "span_ops":
25-
continue
19+
for key in config:
20+
yield key
21+
if isinstance(config[key], dict):
22+
for key in _get_all_keys(config[key]):
2623
yield key
2724

2825

tests/sentry/relay/snapshots/test_config/test_get_project_config/no_ops_breakdown/full_config.pysnap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
created: '2021-05-13T22:16:37.531016Z'
2+
created: '2021-04-26T06:44:48.641788Z'
33
creator: sentry
44
source: tests/sentry/relay/test_config.py
55
---
@@ -13,7 +13,7 @@ config:
1313
- db
1414
- browser
1515
- resource
16-
type: spanOperations
16+
type: span_operations
1717
datascrubbingSettings:
1818
excludeFields: []
1919
scrubData: true

tests/sentry/relay/snapshots/test_config/test_get_project_config/no_ops_breakdown/slim_config.pysnap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
created: '2021-05-13T22:16:37.389823Z'
2+
created: '2021-04-26T06:44:48.504933Z'
33
creator: sentry
44
source: tests/sentry/relay/test_config.py
55
---
@@ -13,7 +13,7 @@ config:
1313
- db
1414
- browser
1515
- resource
16-
type: spanOperations
16+
type: span_operations
1717
datascrubbingSettings:
1818
excludeFields: []
1919
scrubData: true

tests/sentry/relay/snapshots/test_config/test_get_project_config/ops_breakdown/full_config.pysnap

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
11
---
2-
created: '2021-05-13T22:16:37.268371Z'
2+
created: '2021-04-26T06:44:48.376070Z'
33
creator: sentry
44
source: tests/sentry/relay/test_config.py
55
---
66
config:
77
allowedDomains:
88
- '*'
9-
breakdowns:
10-
span_ops:
11-
matches:
12-
- http
13-
- db
14-
- browser
15-
- resource
16-
type: spanOperations
179
datascrubbingSettings:
1810
excludeFields: []
1911
scrubData: true

tests/sentry/relay/snapshots/test_config/test_get_project_config/ops_breakdown/slim_config.pysnap

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
11
---
2-
created: '2021-05-13T22:16:37.059214Z'
2+
created: '2021-04-26T06:44:48.135605Z'
33
creator: sentry
44
source: tests/sentry/relay/test_config.py
55
---
66
config:
77
allowedDomains:
88
- '*'
9-
breakdowns:
10-
span_ops:
11-
matches:
12-
- http
13-
- db
14-
- browser
15-
- resource
16-
type: spanOperations
179
datascrubbingSettings:
1810
excludeFields: []
1911
scrubData: true

0 commit comments

Comments
 (0)