Skip to content

fix(event_manager): Emit TRANSACTION outcomes if metrics are disabled - #41607

Merged
jan-auer merged 4 commits into
masterfrom
fix/transaction-outcomes-no-extraction
Nov 22, 2022
Merged

jan-auer merged 4 commits into
masterfrom
fix/transaction-outcomes-no-extraction

Conversation

@jan-auer

@jan-auer jan-auer commented Nov 21, 2022 •

Copy link
Copy Markdown
Member

In #40507 we started to count transaction metrics in the transaction data category and transaction events in the transaction_indexed data category. That PR missed that metrics extraction can be disabled, in which case the old behavior of counting events as transaction should remain. Relay already implemented this logic since getsentry/relay#1537 based on the metrics extraction flag.

This PR adds a feature check to the organizations:transaction-metrics-extraction feature, which is the same feature flag used to control Relay's behavior. We also remove the previously used option to sample a percentage of organizations into metrics extraction.

The default for this feature remains off (False) until metrics components have been added to all deployment targets including self-hosted.

Note: This requires that the above is set, and that relay.transaction-metrics-org-sample-rate is no longer used for this.

Requires getsentry/getsentry#8935
Fixes getsentry/team-ingest#1

@jjbayer jjbayer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment thread src/sentry/conf/server.py
# Extract metrics for sessions during ingestion.
"organizations:metrics-extraction": False,
# Extraction metrics for transactions during ingestion.
"organizations:transaction-metrics-extraction": False,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was missing entirely. The default was implicitly False.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we remove this flag's fallback to Flagr? Currently it has a True for the fallback.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 It's removed with 3659729.

Comment thread src/sentry/conf/server.py
#
# XXX(ja): DO NOT ENABLE UNTIL THIS NOTICE IS GONE. Relay experiences
# gradual slowdown when this is enabled for too many projects.
# Extract metrics for sessions during ingestion.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The slowdown in Relay was resolved in getsentry/relay#1065

@jan-auer

Copy link
Copy Markdown
Member Author

We must deploy https://github.com/getsentry/getsentry/pull/8935 before we can merge this.

@jjbayer Both could have been deployed together. We have deployed in the meanwhile, though.

@jjbayer

jjbayer commented Nov 22, 2022

Copy link
Copy Markdown
Member

Both could have been deployed together. We have deployed in the meanwhile, though.

@jan-auer right, forgot that both repos are part of the same deploy for a moment.

@jan-auer
jan-auer merged commit abcccb3 into master Nov 22, 2022
@jan-auer
jan-auer deleted the fix/transaction-outcomes-no-extraction branch November 22, 2022 08:19
naterator pushed a commit that referenced this pull request Nov 22, 2022
…#41607)

In #40507 we started to count transaction metrics in the `transaction`
data category and transaction events in the `transaction_indexed` data
category. That PR missed that metrics extraction can be disabled, in
which case the old behavior of counting events as `transaction` should
remain. Relay already implemented this logic since getsentry/relay#1537
based on the metrics extraction flag.

This PR adds a feature check to the
`organizations:transaction-metrics-extraction` feature, which is the
same feature flag used to control Relay's behavior. We also remove the
previously used option to sample a percentage of organizations into
metrics extraction.

The default for this feature remains off (`false`) until metrics
components have been added to all deployment targets including
self-hosted.

Co-authored-by: Matej Minar <[email protected]>
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 7, 2022

This branch was successfully deployed

2 active deployments
Preview – storybook — 3659729c Deployed Nov 21, 2022 by vercel[bot]
Preview – sentry — 3659729c Deployed Nov 21, 2022 by vercel[bot]
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants