Renz
3ef57bb2f5
polish: Week 2 improvements - error messages, progress, performance
## Error Message Improvements (Phase 1)
- ✅ Cluster backup: Added database type context to error messages
- ✅ Rate limiting: Show specific host and wait time in errors
- ✅ Connection failures: Added troubleshooting steps (3-point checklist)
- ✅ Encryption errors: Include backup location in failure messages
- ✅ Archive not found: Suggest cloud:// URI for remote backups
- ✅ Decryption: Hint about wrong key verification
- ✅ Backup directory: Include permission hints and --backup-dir suggestion
- ✅ Backup execution: Show database name and diagnostic checklist
- ✅ Incremental: Better base backup path guidance
- ✅ File verification: Indicate silent command failure possibility
## Progress Indicator Enhancements (Phase 2)
- ✅ ETA calculations: Real-time estimation based on transfer speed
- ✅ Speed formatting: formatSpeed() helper (B/KB/MB/GB per second)
- ✅ Byte formatting: formatBytes() with proper unit scaling
- ✅ Duration display: Improved to show Xm Ys format vs decimal
- ✅ Progress updates: Show [%] bytes/total (speed, ETA: time) format
## Performance Optimization (Phase 3)
- ✅ Buffer sizes: Increased stderr read buffers from 4KB to 64KB
- ✅ Scanner buffers: 64KB initial, 1MB max for command output
- ✅ I/O throughput: Better buffer alignment for streaming operations
## Code Cleanup (Phase 4)
- ✅ TODO comments: Converted to descriptive comments
- ✅ Method calls: Fixed GetDatabaseType() -> DisplayDatabaseType()
- ✅ Build verification: All changes compile successfully
## Summary
Time: ~1.5h (2-4h estimated)
Changed: 4 files (cmd/backup_impl.go, cmd/restore.go, internal/backup/engine.go, internal/progress/detailed.go)
Impact: Better UX, clearer errors, faster I/O, cleaner code
2025-11-26 10:30:29 +00:00
..
2025-11-25 15:25:56 +00:00
2025-11-26 10:30:29 +00:00
2025-11-25 22:29:58 +00:00
2025-11-25 15:25:56 +00:00
2025-11-25 21:31:21 +00:00
2025-11-25 21:31:21 +00:00
2025-11-25 15:25:56 +00:00
2025-11-26 07:44:09 +00:00
2025-11-25 15:25:56 +00:00
2025-11-26 07:25:34 +00:00
2025-11-25 15:25:56 +00:00
2025-11-26 07:54:25 +00:00
2025-11-25 15:25:56 +00:00
2025-11-26 10:30:29 +00:00
2025-11-25 20:30:28 +00:00
2025-11-25 19:18:07 +00:00
2025-11-26 10:30:29 +00:00
2025-11-25 15:25:56 +00:00
2025-11-26 05:25:35 +00:00
2025-11-25 19:18:07 +00:00