Add guarded update snapshots and rollback guidance - #2545
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (8)
Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review. 📝 WalkthroughWalkthroughAdds update preparation and completion commands. The workflow validates Composer platform requirements, captures protected application and database snapshots, prunes retained snapshots, and reports health-check failures with rollback guidance. ChangesUpdate safety workflow
Sequence Diagram(s)sequenceDiagram
participant Operator
participant PrepareUpdateCommand
participant UpdateCompatibilityService
participant Composer
participant UpdateSnapshotService
Operator->>PrepareUpdateCommand: provide update options
PrepareUpdateCommand->>UpdateCompatibilityService: validate target requirements
UpdateCompatibilityService->>Composer: run check-platform-reqs
Composer-->>UpdateCompatibilityService: return compatibility result
PrepareUpdateCommand->>UpdateSnapshotService: capture snapshot
UpdateSnapshotService-->>PrepareUpdateCommand: return snapshot details
PrepareUpdateCommand-->>Operator: report preparation status
sequenceDiagram
participant Operator
participant FinishUpdateCommand
participant RunHealthChecksCommand
participant UpdateSnapshotService
Operator->>FinishUpdateCommand: finish update
FinishUpdateCommand->>RunHealthChecksCommand: run health checks
RunHealthChecksCommand-->>FinishUpdateCommand: return health result
FinishUpdateCommand->>UpdateSnapshotService: resolve snapshot on failure
UpdateSnapshotService-->>FinishUpdateCommand: return rollback guide
FinishUpdateCommand-->>Operator: report healthy or unhealthy status
Merge Risk: ⚪ Minimal · up to The PR adds guarded update snapshots, compatibility checks, retention, health checks, and rollback guidance; no actionable merge-blocking risk remains beyond normal checks and review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
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 |
Summary
.env, Composer state, metadata, and a WAL-safe SQLite backup or driver-specific database guidanceContext
This is the final focused PR split from #2529, covering the update snapshot and rollback tooling requested during review. It is independent of the installer preflight PR.
Safety details
--composer, a localcomposer.phar, or PATH; PATH availability is not assumed.VACUUM INTO, including committed WAL data.0700directories and0600files) and retention defaults to three.Validation
vendor/bin/pest tests/Integration/Maintenance/UpdateSafetyTest.php— 6 passed, 19 assertions