Improved progress display

Previously, the progress bar updated only after completing an entire table.

For large tables such as LIBARC, this could make the application appear to have stopped responding.

Phase 10 updates the interface while rows are being exported.
This commit is contained in:
Mark Gregory
2026-10-16 22:14:53 +01:00
parent e177b1d1ea
commit 9c5c0b5a91
11 changed files with 223 additions and 45 deletions
+8
View File
@@ -0,0 +1,8 @@
# Phase 10 — Live export progress
- Updates export progress while each streamed table is being written, rather than only after the table completes.
- Displays current-table row count, expected row count, and total exported rows.
- Throttles UI updates to every 500 rows (and at the last row) to reduce overhead.
- Retains Phase 9's single-result streaming, InnoDB snapshot, row count verification and SHA-256 sidecars.
Limitations: Large individual values remain constrained by MySQL packet sizes. Progress updates are best effort and may be delayed by networking. Export consistency excludes concurrent DDL and non-InnoDB data. This source has not been built with Xcode or tested against a live server.
+13
View File
@@ -0,0 +1,13 @@
# Phase 11 — Streaming SQL import
- Reads SQL dumps in 64 KiB file chunks, buffering only a line and the current SQL statement.
- Supports DELIMITER directives, SQL quoting, line/block comments and routine bodies.
- Reports statement number and starting line on SQL execution errors.
- Reports approximate byte progress and allows cancellation between statements.
- Verifies SHA-256 sidecar before import if present.
## Limitations
- A single huge SQL statement or line is still buffered in memory.
- Import is nontransactional and cancellation can leave partial changes.
- Parser assumes UTF-8 input and standard MySQL SQL mode (not NO_BACKSLASH_ESCAPES).
- This has not been built with Xcode or integration-tested against MySQL.
+10
View File
@@ -0,0 +1,10 @@
# Phase 12 — Restore Validation
- Exports now create `<backup>.sql.manifest.json` alongside SQL and SHA-256 files.
- The manifest records the selected database, table names and snapshot row counts, view names, trigger names, and routine names/types.
- **Verify Restored Database…** selects an SQL backup and checks its manifest against the selected live database. It optionally verifies the SQL SHA-256 sidecar before checking.
- Reports mismatched table row counts, missing or inaccessible views/triggers/routines, and successful checks. Validation is read-only.
- Structure-only exports record a `null` row count; row-count comparison is skipped for those tables.
- This does **not** validate row content, schema definitions, or guarantee a complete/restorable backup. Do not use as a substitute for a test restore and independent backups.
- Requires appropriate MySQL privileges for SHOW CREATE operations. No external utilities.
- Full Xcode build and live-server tests have not been performed.