Refactor message body full-text search configuration and tests - #5708
Open
johnsimons wants to merge 2 commits into
Open
Refactor message body full-text search configuration and tests#5708johnsimons wants to merge 2 commits into
johnsimons wants to merge 2 commits into
Conversation
The `EnableFullTextSearchOnBodies` setting is only honored by the RavenDB persister, which uses it to control whether message bodies are indexed for full-text search. EF Core persisters, by design, always index message bodies. This change removes the redundant `EnableFullTextSearchOnBodies` setting from the EF Core persistence configuration. Corresponding acceptance tests are updated: a new test is added specifically for RavenDB to verify that the setting correctly disables body search, while the previously shared test for disabled body search is removed as it's not applicable to EF Core.
Search introduces IFullTextSearchDialect beside IIngestionSqlDialect. The full text indexes already existed but nothing queried them. SQL Server ORs two FREETEXT predicates, PostgreSQL matches the indexed tsvector against websearch_to_tsquery with the terms rejoined by OR, so both keep the OR semantics RavenDB's Search defaults to. PostgreSQL only uses an expression index when the query expression parses to the same tree, and a mismatch is silent: search keeps working, on a sequential scan. The indexed expression is now a constant written the way EF renders it, and FullTextSearchIndexTests fails if the two drift apart. SQL Server setup now fails with a named error when the Full-Text Search feature is missing, rather than migrating into an instance whose search endpoint throws.
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.
The
EnableFullTextSearchOnBodiessetting is only honored by the RavenDB persister, which uses it to control whether message bodies are indexed for full-text search. EF Core persisters, by design, always index message bodies.This change removes the redundant
EnableFullTextSearchOnBodiessetting from the EF Core persistence configuration. Corresponding acceptance tests are updated: a new test is added specifically for RavenDB to verify that the setting correctly disables body search, while the previously shared test for disabled body search is removed as it's not applicable to EF Core.