openyurt icon indicating copy to clipboard operation
openyurt copied to clipboard

Proposal for improve yurthub cache

Open JameKeal opened this issue 2 years ago • 8 comments

What type of PR is this?

Uncomment only one /kind <> line, hit enter to put that in a new line, and remove leading whitespace from that line: /kind bug /kind documentation /kind enhancement /kind good-first-issue /kind feature /kind question /kind design /sig ai /sig iot /sig network /sig storage

/kind design

What this PR does / why we need it:

  1. Sorting out the original architecture logic, identifying problems and proposing solutions
  2. Optimized architectural design, weakened YurtHub cloud-side two patterns code design

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

/assign @rambohe-ch

Does this PR introduce a user-facing change?


other Note

JameKeal avatar Jul 15 '23 08:07 JameKeal

@JameKeal: GitHub didn't allow me to assign the following users: your_reviewer.

Note that only openyurtio members, repo collaborators and people who have commented on this issue/PR can be assigned. Additionally, issues/PRs can only have 10 assignees at the same time. For more information please see the contributor guide

In response to this:

What type of PR is this?

Uncomment only one /kind <> line, hit enter to put that in a new line, and remove leading whitespace from that line: /kind bug /kind documentation /kind enhancement /kind good-first-issue /kind feature /kind question /kind design /sig ai /sig iot /sig network /sig storage

/kind design

What this PR does / why we need it:

  1. Sorting out the original architecture logic, identifying problems and proposing solutions
  2. Optimized architectural design, weakened YurtHub cloud-side two patterns code design

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

/assign @rambohe-ch

Does this PR introduce a user-facing change?


other Note

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

openyurt-bot avatar Jul 15 '23 08:07 openyurt-bot

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 51.68%. Comparing base (7fe6fd6) to head (2240828). Report is 213 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1614      +/-   ##
==========================================
+ Coverage   51.42%   51.68%   +0.26%     
==========================================
  Files         134      218      +84     
  Lines       15947    26521   +10574     
==========================================
+ Hits         8200    13707    +5507     
- Misses       7001    11574    +4573     
- Partials      746     1240     +494     
Flag Coverage Δ
unittests 51.68% <ø> (+0.26%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Jul 15 '23 08:07 codecov[bot]

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: JameKeal To complete the pull request process, please assign rambohe-ch You can assign the PR to them by writing /assign @rambohe-ch in a comment when ready.

The full list of commands accepted by this bot can be found 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

openyurt-bot avatar Jul 18 '23 01:07 openyurt-bot

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.4% 0.4% Duplication

sonarqubecloud[bot] avatar Jul 25 '23 08:07 sonarqubecloud[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Oct 24 '23 02:10 stale[bot]

@JameKeal @rambohe-ch Disscussion summary of weekly meeting at 2023.07.26.

  1. Add metrics for cache, like failed times, data size, etc. @rambohe-ch
  2. Original atomic ReplaceComponentList operation is replaced with multiple operations(like update, add, delete) in this proposal which is not atomic. Considering the case that yurthub is doing such "multiple operations" to cache the list response but failed by crash, the cached data on disk is incompleted and after restoring of yurthub it will use the incomplete data to serve client requests. The situation will not be relieved until the client sends a relist request and the yurthub sucessfully caches the new responses. @Congrool
  3. The underlayer of the Store interface may be diskStorage or etcdStorage. If the interface is modified, the implementation of etcdStorage should also be aligned with it. @Congrool

Congrool avatar Nov 26 '23 10:11 Congrool

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Feb 24 '24 10:02 stale[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 02 '24 21:06 stale[bot]