lsroot
|
b037a729cd
|
feat(sync): Phase 1 - Implement batch transmission optimization
Optimize client-server log synchronization performance with batch processing.
Server-side changes:
- Add TYPE_SYNC_BATCH (0x14) packet type
- Implement batch transmission in TsSyncStored() (BATCH_SIZE=100)
- Add SyncPackerBatch structure for batch packets
- Add performance monitoring with timing logs
Client-side changes:
- Add TYPE_SYNC_BATCH packet type definition
- Implement batch packet validation in isValidSyncPacket()
- Add batch processing logic in processSyncPacket()
- Optimize UI updates with setUpdatesEnabled() for batch operations
- Add sync performance tracking and display
Performance improvements:
- Reduce WebSocket calls from N to N/100 (99% reduction)
- Reduce UI update operations by 99%
- Expected sync time for 3000 logs: 6s -> 1.5s (75% improvement)
Related issue: Slow sync performance with 3000+ logs
|
2025-10-24 01:51:57 +08:00 |
|