Skip to content

feat: implement filter cache rebuilding for mapping, SUPP, and validation#286

Merged
rubentalstra merged 1 commit intomainfrom
perf/Optimization-Implementation
Jan 26, 2026
Merged

feat: implement filter cache rebuilding for mapping, SUPP, and validation#286
rubentalstra merged 1 commit intomainfrom
perf/Optimization-Implementation

Conversation

@rubentalstra
Copy link
Owner

This pull request refactors the toast notification and auto-save mechanisms in the TSS GUI to use event-driven, one-shot timers instead of polling subscriptions. It also introduces helper functions to rebuild filter caches in the domain editor, ensuring UI consistency after relevant data changes. Several code paths now trigger cache rebuilds and auto-save checks more reliably. The subscription system is simplified as a result of these changes.

Event-driven timers for toast and auto-save:

  • Replaces polling subscriptions for toast auto-dismiss and auto-save debounce with Task::perform-based one-shot timers, improving efficiency and responsiveness. The new approach schedules a timer when a toast is shown or when changes are made, rather than polling at fixed intervals. [1] [2] [3] [4]

Domain editor UI cache management:

  • Adds helper functions (rebuild_mapping_cache, rebuild_supp_cache, rebuild_validation_cache) to rebuild filter caches for mapping, SUPP, and validation views, ensuring UI state stays in sync with data changes. These are called after relevant actions in the domain editor. [1] [2] [3]

Improved auto-save and cache rebuild triggers:

  • Updates mapping-related message handlers in the domain editor to rebuild caches and trigger auto-save checks after actions that affect mapping or filters, ensuring that UI and autosave are always up-to-date. [1] [2] [3] [4] [5] [6] [7]

Subscription system simplification:

  • Removes toast and auto-save polling subscriptions from the main subscription batch, as these are now handled by event-driven timers. Updates documentation and code comments to reflect this architectural change. [1] [2] [3]

Startup and feedback improvements:

  • Ensures toast notifications (such as update success messages) and toast dismissals are now scheduled as tasks at startup and after relevant events, providing a smoother user experience. [1] [2] [3] [4] [5]

These changes collectively improve UI responsiveness, reduce unnecessary background work, and make the codebase easier to maintain.

@rubentalstra rubentalstra merged commit 921bb8b into main Jan 26, 2026
12 checks passed
@rubentalstra rubentalstra deleted the perf/Optimization-Implementation branch January 26, 2026 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant