Introduced ConnectionManager to support offline-first architecture: - New internal/db/connection.go with thread-safe connection management - Lazy connection establishment (5s timeout, 10s cooldown) - Automatic ping caching (30s interval) to avoid excessive checks - Updated middleware/offline.go to use ConnectionManager.IsOnline() - Updated sync/worker.go to use ConnectionManager instead of direct DB This enables the application to start without MariaDB and gracefully handle offline/online transitions. Part of Phase 2.5: Full Offline Mode Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
750 B
750 B