perf(connections): debounce tree object filters and the sidebar connection search (#878) - #976
Merged
ZhuchkaTriplesix merged 1 commit intoSep 25, 2026
Conversation
…ction search (Closes #878) The PostgreSQL / MySQL / SQLite object-group filters and the sidebar 'Filter connections...' field called setState on every keystroke, re-filtering and rebuilding the whole subtree each time. Add FilterDebouncer (150 ms, the same as the data grid filter bar) and apply the query only after the user pauses. Clearing cancels a pending update and takes effect immediately. In the sidebar, the search icon and clear button are driven by the text controller through ValueListenableBuilders, so they still react to every keystroke without rebuilding the panel.
ZhuchkaTriplesix
deleted the
issue/878-debounce-tree-filter-sidebar-search
branch
September 28, 2026 08:13
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Описание изменений
setStateна каждый символ, а значит заново фильтровали список и перестраивали всё поддерево.FilterDebouncerиkTreeFilterDebounce= 150 мс (как у фильтра сетки). Запрос применяется только после паузы в наборе. Кнопка очистки отменяет отложенное применение и срабатывает сразу; таймеры отменяются вdispose.TextEditingControllerчерезValueListenableBuilder, поэтому реагируют на каждый символ без перестройки всей панели, а сам список подстраивается через 150 мс.itemExtent), менялся только момент применения запроса.connection_tree_quick_search_test:FilterDebouncer(выполняется только последнее действие,cancelотменяет), набор в сайдбаре применяется один раз после паузы, очистка сбрасывает фильтр сразу и отложенный ввод не возвращает его. Весь каталогtest/features/connections(59 тестов) прогнал локально, проходят.Не входит
_PgObjectGroupи т.п.) приватные и в тест напрямую не попадают, поэтому их дебаунс покрыт тестом самогоFilterDebouncerи проверкой в сайдбаре, а не отдельным виджет-тестом дерева.listTables/listBrowsableRelations(как в issue).Связанные Issue
Closes #878