Skip to content

fix: Deflake DaprJobsIT and let CI integration retries finish - #1827

Merged
siri-varma merged 2 commits into
dapr:masterfrom
javier-aliaga:fix/ci-flaky-tests
Oct 8, 2026
Merged

siri-varma merged 2 commits into
dapr:masterfrom
javier-aliaga:fix/ci-flaky-tests

Conversation

@javier-aliaga

Copy link
Copy Markdown
Contributor

Description

Two fixes for the recent Build job failures, found by checking every Build job since 2026-09-16, including reruns.

DaprJobsIT time comparison. The tests formatted the expected due time with a fixed .SSS pattern and compared it with Instant.toString(), which drops the fraction when the milliseconds are zero. The test then failed with expected: <2026-09-30T09:25:00.000Z> but was: <2026-09-30T09:25:00Z>. This was seen on master and on a PR branch. The tests now compare the Instant values, truncated to milliseconds. Both copies are fixed, in sdk-tests and spring-boot-sdk-tests.

Job timeouts. One integration attempt takes 20 to 22 minutes. The Build job timeout was 25 minutes, so the nick-fields/retry second attempt was always cancelled, and a flaky test showed up as a cancelled job. The Build job timeout is now 60 minutes, which fits two 25-minute attempts plus the install step. The dapr-head job timeout is now 50 minutes, which fits two 20-minute attempts.

The other frequent failure, OrchestratorAppIT, came from a daprd 1.18.0 read error (inbox key ... declared in metadata but missing from state store). dapr fixed it in 1.18.3, and master picked up the fix with the move to 1.19.0-rc.1 in #1820, so this PR does not change it.

Test plan

  • Both DaprJobsIT suites pass locally under JDK 17 (6/6 each)
  • jshell check: the old comparison fails and the new one passes for a due time with zero milliseconds
  • CI green

DaprJobsIT compared the expected due time, always formatted with
milliseconds, against Instant.toString(), which drops them when they are
zero. The tests now compare Instants truncated to milliseconds.

The build job timeout equalled one integration attempt, so the retry was
cancelled before it could finish. Raise the job timeouts to fit both
attempts.

Signed-off-by: Javier Aliaga <javier@diagrid.io>
Copilot AI balanced review requested due to automatic review settings October 7, 2026 07:51
@javier-aliaga
javier-aliaga requested review from a team as code owners October 7, 2026 07:51

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🟢 Approval recommended

The changes correctly address timestamp formatting flakes and permit configured retries to finish.

Review effort: Balanced
Findings: None

What changed in this PR

Deflakes jobs integration tests and allows CI retries enough time to complete.

Changes:

  • Compares job timestamps as millisecond-precision Instant values.
  • Extends Build and Dapr-head job timeouts.
File Description
spring-boot-sdk-tests/​.../​DaprJobsIT.java Uses precision-safe timestamp assertions.
sdk-tests/​.../​DaprJobsIT.java Uses precision-safe timestamp assertions.
.github/​workflows/​build.yml Increases CI job timeout limits.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@siri-varma

Copy link
Copy Markdown
Contributor

@javier-aliaga I think each retry gets 20 mins.

@javier-aliaga

Copy link
Copy Markdown
Contributor Author

@javier-aliaga I think each retry gets 20 mins.

@siri-varma we have 2 different timeouts at job level and on the retry, the job level one is the one I am modifying and it is not aware of attemtps, it must be the total of time. For example https://github.com/dapr/java-sdk/actions/runs/35599938362/job/106333386556

The Durable Task job allowed 7 minutes while its retry step allows two
5-minute attempts, so a second attempt had about a minute and a half.
Raise the job timeout to 15 minutes and note on each retried job that
the job timeout covers every attempt.

Signed-off-by: Javier Aliaga <javier@diagrid.io>
Copilot AI balanced review requested due to automatic review settings October 8, 2026 09:01

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

The timestamp precision and workflow timeout changes are consistent with the underlying serialization and retry configuration.

0 open findings

🧠 Review effort: Balanced


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

@codecov

codecov Bot commented Oct 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.66%. Comparing base (8f59769) to head (42d4269).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1827      +/-   ##
============================================
+ Coverage     79.26%   79.66%   +0.39%     
- Complexity     2615     2683      +68     
============================================
  Files           264      267       +3     
  Lines          7785     7923     +138     
  Branches        820      839      +19     
============================================
+ Hits           6171     6312     +141     
+ Misses         1254     1252       -2     
+ Partials        360      359       -1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@siri-varma
siri-varma merged commit 77f6794 into dapr:master Oct 8, 2026
16 checks passed
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