Skip to content

fix: make complete family update transactional#485

Merged
JuliusHenke merged 1 commit into
masterfrom
fix/family-update-transaction
May 20, 2026
Merged

fix: make complete family update transactional#485
JuliusHenke merged 1 commit into
masterfrom
fix/family-update-transaction

Conversation

@JuliusHenke
Copy link
Copy Markdown
Member

This mitigates an issue where previous family data would be cleared, while the later update of the families might not pass leaving it in a state with empty family data.

This mitigates an issue where previous family data would be cleared, while the later update of the families might not pass leaving it in a state with empty family data.
Copilot AI review requested due to automatic review settings May 20, 2026 16:46
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR makes relay family recomputation atomic per-month by ensuring the “clear existing families” step and the subsequent re-save happen within the same database transaction, preventing months from ending up with empty family data if the update fails mid-way.

Changes:

  • Inject TransactionTemplate into RelayDetailsUpdateService.
  • Wrap each computeFamiliesForMonth(month) execution (run via CoalesceService.submitAsync) in a transaction using transactionTemplate.executeWithoutResult { ... }.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@JuliusHenke JuliusHenke merged commit a442ed7 into master May 20, 2026
7 checks passed
@JuliusHenke JuliusHenke deleted the fix/family-update-transaction branch May 20, 2026 16:53
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.

2 participants