Skip to content

[probes.http] Streamline payload metrics handling - #1017

Merged
manugarg merged 2 commits into
mainfrom
http-probe-1
Feb 27, 2025
Merged

manugarg merged 2 commits into
mainfrom
http-probe-1

Conversation

@manugarg

@manugarg manugarg commented Feb 26, 2025 •

Copy link
Copy Markdown
Contributor
  • For payload metrics in HTTP probe, we'll now store metrics in the probeResult instead of pushing to dataChan and as a result expecting dataChan to be defined. I realized this will be better while trying to implement the single run interface (Add a single run interface #969) for the HTTP probe -- we'll not use dataChan for that.
  • Simplify how we decide if an EventMetrics is for alerting: Change options.RecordMetrics to only look at the EM's NotForAlerting option to decide whether to send this EM to alert handlers.
  • Add EventMetrics option NotForAlerting to all payload metrics by default, instead of handling that in probes: http, browser, external.
  • This change also includes changes to metrics.EventMetrics:
    • I'm adding a method called Equal that allows comparing two EventMetrics. There is also an option to compare w/o timestamps. Since we compare EventMetrics in a lot of tests, I think this function will be useful.
    • Also making setting NotForAlerting and checking if this EM is for alerting simpler.

@manugarg
manugarg merged commit ebb3ca9 into main Feb 27, 2025
@manugarg
manugarg deleted the http-probe-1 branch February 27, 2025 01:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant