Skip to content

Fix Search Again#610

Merged
jondricek merged 1 commit into
masterfrom
develop
Jun 23, 2026
Merged

Fix Search Again#610
jondricek merged 1 commit into
masterfrom
develop

Conversation

@jondricek

Copy link
Copy Markdown
Contributor

This pull request improves the reliability of the search index backup process by ensuring that the backup only occurs after FlexSearch has finished indexing all documents. It also updates the search cache schema version to reflect this behavioral change. The most important changes are:

Search Index Initialization and Backup:

  • Modified SearchService.initializeAsync in search-service.js to await the completion of attackIndex.addBulk before starting the backup, ensuring that the search index is fully built before backup begins.

Testing Improvements:

  • Added a test in search-service.test.js to verify that the backup process waits for FlexSearch indexing to complete before running.

Versioning:

  • Incremented the searchCacheSchemaVersion from 2 to 3 in settings.js to indicate a breaking change in the search cache logic.

@jondricek jondricek merged commit 57f7b38 into master Jun 23, 2026
4 checks passed
@sonarqubecloud

Copy link
Copy Markdown

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