Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: optimize the implementation of indexed query engine through query index view #5233

Merged
merged 1 commit into from
Jan 24, 2024

Conversation

guqing
Copy link
Member

@guqing guqing commented Jan 23, 2024

What type of PR is this?

/kind improvement
/area core
/milestone 2.12.x

What this PR does / why we need it:

通过重构 QueryIndexView 的实现方式来优化 IndexedQueryEngine 的逻辑并简化排序过程

how to test it?
单元测试通过即可,此 PR 的修改都是基于单元测试的基础上对原代码做的重构

Does this PR introduce a user-facing change?

None

@f2c-ci-robot f2c-ci-robot bot added kind/improvement Categorizes issue or PR as related to a improvement. release-note-none Denotes a PR that doesn't merit a release note. labels Jan 23, 2024
@f2c-ci-robot f2c-ci-robot bot added this to the 2.12.x milestone Jan 23, 2024
@f2c-ci-robot f2c-ci-robot bot added the area/core Issues or PRs related to the Halo Core label Jan 23, 2024
@f2c-ci-robot f2c-ci-robot bot requested review from minliacom and ruibaby January 23, 2024 07:05
Copy link

codecov bot commented Jan 23, 2024

Codecov Report

Attention: 22 lines in your changes are missing coverage. Please review.

Comparison is base (14580b9) 57.06% compared to head (e21daea) 57.14%.
Report is 4 commits behind head on main.

Files Patch % Lines
.../app/extension/index/query/QueryIndexViewImpl.java 90.00% 5 Missing and 8 partials ⚠️
...va/run/halo/app/extension/index/KeyComparator.java 84.00% 2 Missing and 2 partials ⚠️
...n/halo/app/extension/index/query/QueryFactory.java 33.33% 2 Missing and 2 partials ⚠️
...lo/app/extension/index/IndexedQueryEngineImpl.java 94.44% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #5233      +/-   ##
============================================
+ Coverage     57.06%   57.14%   +0.08%     
- Complexity     3333     3384      +51     
============================================
  Files           584      587       +3     
  Lines         19190    19247      +57     
  Branches       1444     1460      +16     
============================================
+ Hits          10950    10999      +49     
  Misses         7664     7664              
- Partials        576      584       +8     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@guqing guqing force-pushed the refactor/index-view branch from b4e75d0 to e21daea Compare January 23, 2024 09:32
Copy link
Member

@JohnNiang JohnNiang left a comment

Choose a reason for hiding this comment

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

/lgtm

@f2c-ci-robot f2c-ci-robot bot added the lgtm Indicates that a PR is ready to be merged. label Jan 24, 2024
Copy link

f2c-ci-robot bot commented Jan 24, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JohnNiang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@f2c-ci-robot f2c-ci-robot bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 24, 2024
@f2c-ci-robot f2c-ci-robot bot merged commit 57fb644 into halo-dev:main Jan 24, 2024
7 checks passed
@ruibaby ruibaby modified the milestones: 2.12.x, 2.12.0 Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/core Issues or PRs related to the Halo Core kind/improvement Categorizes issue or PR as related to a improvement. lgtm Indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants