Open ikaven1024 opened 2 weeks ago
[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by:
To complete the pull request process, please assign xishanyongye-chang after the PR has been reviewed.
You can assign the PR to them by writing /assign @xishanyongye-chang
in a comment when ready.
The full list of commands accepted by this bot can be found here.
Run karmada-search with --v=4
, and request pods with limit=1 and rv=0, get logs:
I0502 22:55:20.201074 20847 multi_cluster_cache.go:233] List member cluster kwok-cluster1 with &internalversion.ListOptions{TypeMeta:v1.TypeMeta{Kind:"", APIVersion:""}, LabelSelector:labels.internalSelector(nil), FieldSelector:fields.andTerm{}, Watch:false, AllowWatchBookmarks:false, ResourceVersion:"0", ResourceVersionMatch:"", TimeoutSeconds:(*int64)(nil), Limit:1, Continue:"", SendInitialEvents:(*bool)(nil)}
I0502 22:55:20.219607 20847 multi_cluster_cache.go:233] List member cluster kwok-cluster2 with &internalversion.ListOptions{TypeMeta:v1.TypeMeta{Kind:"", APIVersion:""}, LabelSelector:labels.internalSelector(nil), FieldSelector:fields.andTerm{}, Watch:false, AllowWatchBookmarks:false, ResourceVersion:"0", ResourceVersionMatch:"", TimeoutSeconds:(*int64)(nil), Limit:1, Continue:"", SendInitialEvents:(*bool)(nil)}
From the logs, we can see that both two member clusters are accessed with ResourceVersion:"0".
Attention: Patch coverage is 16.66667%
with 5 lines
in your changes are missing coverage. Please review.
Project coverage is 53.11%. Comparing base (
5bc8c54
) to head (7015546
). Report is 2 commits behind head on master.
Files | Patch % | Lines |
---|---|---|
pkg/search/proxy/store/multi_cluster_cache.go | 16.66% | 4 Missing and 1 partial :warning: |
:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Thanks @ikaven1024 , please assign this to @XiShanYongYe-Chang or me once it's ready for review.
What type of PR is this? /kind bug
What this PR does / why we need it: When client request list with rv=0, proxy fetch objects from cache. It works as expected. While when pagination occurs, a
continue
will be responsed. This continue will filled with cluster's versions. https://github.com/karmada-io/karmada/blob/02dad486f9628410de07eb4f3156972c8170073d/pkg/search/proxy/store/multi_cluster_cache.go#L295 And the next paging request will access etcd with version incontinue
. We should make it accessing cache also to improve performance.Which issue(s) this PR fixes:
Special notes for your reviewer:
Does this PR introduce a user-facing change?: