Improve query performance and memory usage by adding a migration to create several indexes and converting various upload/reporting flows to batched processing. Changes include:
- Add migration 245 to create indexes: idx_mode, idx_sat_name, idx_continent, idx_qsl_stats (composite), idx_hrdlog_upload, idx_qrz_upload to speed common queries.
- Bump migration version to 245 in config.
- Hrdlog and Qrz controllers: switch to fetching QSOs in LIMIT/OFFSET batches, process updates in chunks, add logging for batch progress, and use break 2 to stop outer loops on invalid API keys to avoid continuing work.
- Logbook_model:
- get_hrdlog_qsos and get_qrz_qsos now accept limit/offset and use ORDER BY/LIMIT/OFFSET for batching.
- Replaced a subquery with a JOIN for grid-based filtering to improve performance.
- get_modes rewritten to use query builder (distinct/select/order_by).
- Bulk DXCC updates use update_batch instead of per-row queries.
- calls_without_station_id limited to 500 results to avoid UI hangs.
Overall goal: prevent memory exhaustion with large datasets and improve database query performance.