Exclude timeout exception - #927
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthrough
ChangesTransaction retry handling
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryUpdates transaction failure handling across adapters:
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains. Important Files Changed
Reviews (3): Last reviewed commit: "fix comments add tests" | Re-trigger Greptile |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/Database/Adapter.php`:
- Around line 459-460: Update the exception handling around
rollbackTransaction() so non-retriable $action exceptions, including
LimitException and TimeoutException, are rethrown immediately even when rollback
cleanup fails. Preserve the rollback attempt, but ensure rollback failure
handling does not retry or mask these action exceptions; retain existing
behavior for retriable actions.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 16dca011-c9e9-421b-bea3-d4908278a2ec
📒 Files selected for processing (3)
src/Database/Adapter.phpsrc/Database/Adapter/Mongo.phptests/unit/TransactionRetryTest.php
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/Database/Adapter/Redis.php`:
- Around line 4003-4011: Update the rollback failure handling around
rollbackJournal() to clear all remaining journal frames in $journalStack before
resetting $inTransaction to 0 and rethrowing the exception. Preserve the
existing successful rollback behavior and SQL/Mongo transaction-depth contract.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: f920dd6f-3b56-4712-9c9a-23de7bb97fe0
📒 Files selected for processing (3)
src/Database/Adapter.phpsrc/Database/Adapter/Redis.phptests/unit/TransactionRetryTest.php
🚧 Files skipped from review as they are similar to previous changes (1)
- tests/unit/TransactionRetryTest.php
Summary by CodeRabbit