Skip to content

Fix search percentile rank scoring#24859

Merged
Bhanuagr merged 6 commits intomainfrom
fix/search-percentile-rank-scoring
Dec 23, 2025
Merged

Fix search percentile rank scoring#24859
Bhanuagr merged 6 commits intomainfrom
fix/search-percentile-rank-scoring

Conversation

@Bhanuagr
Copy link
Copy Markdown
Contributor

@Bhanuagr Bhanuagr commented Dec 16, 2025

Issue:

Slack Thread

Changes:

  • Update weeklyStats.percentileRank factor from 0.05 to 1.0
  • Update monthlyStats.percentileRank factor from 0.1 to 1.0
  • Add v1114 migration to apply changes to existing installations
  • Preserves user customizations via selective update

Type of change:

  • Bug fix
  • Improvement
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • I have commented on my code, particularly in hard-to-understand areas.
  • For JSON Schema changes: I updated the migration scripts or explained why it is not needed.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes search percentile rank scoring by increasing the boost factors from very low values (0.05 for weekly stats, 0.1 for monthly stats) to 1.0, which should give percentile rank appropriate weight in search relevance calculations. The change includes:

  • Updated default search settings configuration
  • New reusable utility for merging search settings during migrations
  • v1.11.4 migration that selectively updates only the old default values while preserving user customizations

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
searchSettings.json Updates default percentileRank factors from 0.05/0.1 to 1.0 for new installations
SearchSettingsMergeUtil.java New reusable utility providing selective merge capabilities for search settings migrations
v1114/MigrationUtil.java Migration logic to update existing installations, preserving user customizations
mysql/v1114/Migration.java MySQL-specific migration entry point invoking the shared migration util
postgres/v1114/Migration.java PostgreSQL-specific migration entry point invoking the shared migration util
SearchSettingsMergeUtilTest.java Comprehensive test suite covering merge scenarios and edge cases
mysql/schemaChanges.sql Placeholder SQL file indicating Java-based migration
postgres/schemaChanges.sql Placeholder SQL file indicating Java-based migration

The implementation is well-designed with excellent separation of concerns, comprehensive testing, and safe migration logic that respects user customizations. The code follows Java best practices and is consistent with existing migration patterns in the codebase.

@github-actions
Copy link
Copy Markdown
Contributor

Jest test Coverage

UI tests summary

Lines Statements Branches Functions
Coverage: 64%
64.28% (50819/79056) 41.94% (24786/59101) 45.36% (7797/17189)

@sonarqubecloud
Copy link
Copy Markdown

@sonarqubecloud
Copy link
Copy Markdown

@Bhanuagr Bhanuagr merged commit 71b23f1 into main Dec 23, 2025
44 of 47 checks passed
@Bhanuagr Bhanuagr deleted the fix/search-percentile-rank-scoring branch December 23, 2025 18:06
@github-actions
Copy link
Copy Markdown
Contributor

Failed to cherry-pick changes to the 1.11.4 branch.
Please cherry-pick the changes manually.
You can find more details here.

Bhanuagr added a commit that referenced this pull request Dec 23, 2025
* Fix search percentile rank scoring

* Added support for generic methods to merge search settings properties

* Added tests for search settings merge util

* Fixed palywright test for Restore default search settings
ShaileshParmar11 pushed a commit that referenced this pull request Dec 26, 2025
* Fix search percentile rank scoring

* Added support for generic methods to merge search settings properties

* Added tests for search settings merge util

* Fixed palywright test for Restore default search settings
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend safe to test Add this label to run secure Github workflows on PRs To release Will cherry-pick this PR into the release branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants