97e294f1d6
Replaced open/close-per-operation pattern with a single persistent connection held for the app lifetime. This prevents the DB upgrade (v1→v2) from being blocked by lingering connections, and eliminates transaction contention. Also added onblocked handler that surfaces a clear error instead of hanging indefinitely.