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

feat: back to source with piece group #2826

Merged
merged 9 commits into from
Dec 27, 2023

Conversation

jim3ma
Copy link
Member

@jim3ma jim3ma commented Oct 24, 2023

Description

Currently, for multiple pieces tasks, we download them by one piece for one request, download them by multiple pieces(piece group) is a better solution. This PR implements it.

Related Issue

Motivation and Context

Screenshots (if appropriate)

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation Update (if none of the other choices apply)

Checklist

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.

@jim3ma jim3ma requested a review from a team as a code owner October 24, 2023 07:56
@codecov
Copy link

codecov bot commented Oct 24, 2023

Codecov Report

Merging #2826 (1ff13bd) into main (3dc2e46) will decrease coverage by 1.11%.
Report is 57 commits behind head on main.
The diff coverage is 78.75%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2826      +/-   ##
==========================================
- Coverage   52.06%   50.95%   -1.11%     
==========================================
  Files         157      161       +4     
  Lines       21364    21989     +625     
==========================================
+ Hits        11123    11205      +82     
- Misses       9594    10126     +532     
- Partials      647      658      +11     
Flag Coverage Δ
Object-compatibility-e2etests ?
e2etests ?
unittests 50.95% <78.75%> (-1.11%) ⬇️

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

Files Coverage Δ
client/daemon/storage/local_storage.go 31.28% <0.00%> (ø)
client/daemon/storage/local_storage_subtask.go 26.85% <50.00%> (ø)
client/daemon/peer/piece_manager.go 48.74% <79.61%> (-4.41%) ⬇️

... and 21 files with indirect coverage changes

@jim3ma jim3ma changed the title [WIP] chore: split concurrentDownloadSource [WIP] feat: back to source with piece group Oct 31, 2023
Signed-off-by: Jim Ma <majinjing3@gmail.com>
@jim3ma jim3ma force-pushed the feat/back-to-source-with-piece-group branch from 009cf3b to d612a6f Compare October 31, 2023 08:59
Signed-off-by: Jim Ma <majinjing3@gmail.com>
Signed-off-by: Jim Ma <majinjing3@gmail.com>
Signed-off-by: Jim Ma <majinjing3@gmail.com>
Signed-off-by: Jim Ma <majinjing3@gmail.com>
Signed-off-by: Jim Ma <majinjing3@gmail.com>
Signed-off-by: Jim Ma <majinjing3@gmail.com>
@jim3ma jim3ma changed the title [WIP] feat: back to source with piece group feat: back to source with piece group Nov 16, 2023
Signed-off-by: Jim Ma <majinjing3@gmail.com>
gaius-qi
gaius-qi previously approved these changes Nov 17, 2023
Copy link
Member

@gaius-qi gaius-qi left a comment

Choose a reason for hiding this comment

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

LGTM

client/daemon/peer/piece_manager.go Outdated Show resolved Hide resolved
client/daemon/peer/piece_manager.go Outdated Show resolved Hide resolved
Signed-off-by: Jim Ma <majinjing3@gmail.com>
Copy link
Member

@gaius-qi gaius-qi left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

@xujihui1985 xujihui1985 left a comment

Choose a reason for hiding this comment

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

LGTM

@jim3ma jim3ma merged commit e329bdb into main Dec 27, 2023
21 checks passed
@jim3ma jim3ma deleted the feat/back-to-source-with-piece-group branch December 27, 2023 07:54
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.

3 participants