Skip to content

chore: implement phase 2 - #2780

Draft
Tofel wants to merge 2 commits into
dx-5122-alerts-assertion-p1from
dx-5122-alerts-assertion-p2
Draft

chore: implement phase 2#2780
Tofel wants to merge 2 commits into
dx-5122-alerts-assertion-p1from
dx-5122-alerts-assertion-p2

Conversation

@Tofel

@Tofel Tofel commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Fix retry-error conflation, measure full poll latency, and harden Source test doubles for concurrency.


Stack created with GitHub Stacks CLIGive Feedback 💬

@github-actions

github-actions Bot commented Sep 1, 2026

Copy link
Copy Markdown

📊 API Diff Results

No changes detected for module github.com/smartcontractkit/chainlink-testing-framework/grafana-alertcheck

View full report

@Tofel
Tofel force-pushed the dx-5122-alerts-assertion-p2 branch from bbd2ebe to 799df17 Compare September 1, 2026 11:25
// skewHardLimit is one of §5's filled-in values (basis: §16; §22.11 asserts
// 120s errors, 30s does not). It belongs in schedule.go's named-constants
// block once P4 exists; defined here because P2 needs it first.
const skewHardLimit = 60 * time.Second

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Clock skew is only ever needed to place the runner-defined window edges [from, to+grace] onto Grafana's own timeline, so it's a single-point reconciliation, not a factor in any duration-based check. The 60s hard limit is therefore a sanity gate, not a correction: skew is estimated as serverDate − (t_send+t_recv)/2 with error RTT/2, and that estimation is only trusted while the two clocks are in rough agreement. Past 60s the offset is treated as a broken or misconfigured clock, so the gate fails closed rather than align fine-grained window work against a clock it no longer trusts.

// verified against (§2.7 control 2, §21.5): >= 13.0.0, < 14.0.0.
var (
supportedGrafanaMin = grafanaVersion{13, 0, 0}
supportedGrafanaMax = grafanaVersion{14, 0, 0} // exclusive

@Tofel Tofel Sep 1, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

better safe than sorry, we don't want to risk subtle behaviour changes.

Fix retry-error conflation, measure full poll latency, and harden Source test doubles for concurrency.
@Tofel
Tofel force-pushed the dx-5122-alerts-assertion-p2 branch from 4159c2f to 3894d9b Compare September 2, 2026 09:45
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