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

fix: blob lost and lack mutex protection #220

Merged
merged 2 commits into from
Oct 24, 2023

Conversation

PerseidMeteor
Copy link
Collaborator

@PerseidMeteor PerseidMeteor commented Oct 20, 2023

If use info varible in Update of store and get error in store update, the return value info is empty, and cache Update will be useless.

change:

  • rename info to updateInfo in content wrap
  • Update func of cache needs a mutex protection
  • add cached info of a conversion like log info
    "pulled image xxx(cached 21/23)"
    "......"
    "converted image xxx(cached 21/23)"
    "......"

pkg/content/content.go Outdated Show resolved Hide resolved
pkg/content/content.go Outdated Show resolved Hide resolved
@PerseidMeteor PerseidMeteor force-pushed the fix-blob-lost branch 5 times, most recently from 8c3fcac to 51cade8 Compare October 22, 2023 08:41
pkg/cache/cache.go Outdated Show resolved Hide resolved
If use info varible in update and get error in store update, the return value info is empty, and cache update will be useless.And Update func of cache needs a mutex protection

Signed-off-by: YuQiang <y_q_email@163.com>
pkg/cache/cache.go Outdated Show resolved Hide resolved
pkg/cache/cache.go Outdated Show resolved Hide resolved
@PerseidMeteor PerseidMeteor force-pushed the fix-blob-lost branch 5 times, most recently from aa03a43 to 879220a Compare October 24, 2023 01:33
add cached layer info in a conversion.eg. converted image xxx(cached 10/13)

Signed-off-by: YuQiang <y_q_email@163.com>
@imeoer imeoer merged commit 95fbdcd into goharbor:main Oct 24, 2023
9 checks passed
@PerseidMeteor PerseidMeteor deleted the fix-blob-lost branch October 24, 2023 06:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants