Skip to content

Conversation

@jjbayer
Copy link
Member

@jjbayer jjbayer commented Oct 31, 2025

Like in #5309, refactor processing helpers to not depend on envelopes / the processor service itself, and move them to processing.

ref: INGEST-610

@linear
Copy link

linear bot commented Oct 31, 2025

project_id: ProjectId,
ctx: processing::Context<'_>,
geo_lookup: &GeoIpLookup,
reservoir_counters: &ReservoirEvaluator<'_>,
Copy link
Member Author

Choose a reason for hiding this comment

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

This argument was passed into the function but was disabled by supports_reservoir_sampling on the Sampled trait.

)
.await;
// If no metrics could be extracted, do not sample anything.
let should_sample = matches!(&ctx.project_info.config().metric_extraction, ErrorBoundary::Ok(c) if c.is_supported());
Copy link
Member Author

Choose a reason for hiding this comment

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

This check was previously evaluated in supports_sampling in the Sampling trait.

// Also, we require transaction metrics to be enabled before sampling.
let run_dynamic_sampling = (matches!(filter_run, FiltersStatus::Ok)
|| self.inner.config.processing_enabled())
&& matches!(&ctx.project_info.config.transaction_metrics, Some(ErrorBoundary::Ok(c)) if c.is_enabled());
Copy link
Member Author

Choose a reason for hiding this comment

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

This check was previously defined in Sampled::supports_sampling.

@jjbayer jjbayer marked this pull request as ready for review October 31, 2025 13:08
@jjbayer jjbayer requested a review from a team as a code owner October 31, 2025 13:08
@jjbayer jjbayer added this pull request to the merge queue Nov 3, 2025
Merged via the queue into master with commit 6a313da Nov 3, 2025
29 checks passed
@jjbayer jjbayer deleted the ref/processor-more-functions branch November 3, 2025 08:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants