Skip to content

fix: keep the latest instance search results - #14

Open
Hanabi9248 wants to merge 2 commits into
IvorySQL:IVYC_REL_5_STABLEfrom
Hanabi9248:codex/keep-latest-instance-search
Open

Hanabi9248 wants to merge 2 commits into
IvorySQL:IVYC_REL_5_STABLEfrom
Hanabi9248:codex/keep-latest-instance-search

Conversation

@Hanabi9248

Copy link
Copy Markdown

Searching twice, or searching and then resetting, can leave the instance table showing an older response if requests finish out of order. A late reset response can also restart polling after a newer search has stopped it.

Use one request counter for Search and Reset, and ignore results and errors from superseded requests before emitting resultList.

Added four regression cases covering reversed search/search, search/reset and reset/search responses, plus stale errors. All four fail before the fix; the full suite passes afterward (8 tests, Node 18). ESLint has no errors; its two warnings concern the fixed method-name table in the test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant