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

chunked: improve function to merge chunks #1846

Conversation

giuseppe
Copy link
Member

improve the function that combines neighbor chunks. Instead of using the number of parts, which also includes local files, use only the number of chunks that must be retrieved from the network.

In addition, introduce a threshold limit to merge chunks so that we further reduce the number of requested ranges.

@giuseppe giuseppe marked this pull request as draft February 28, 2024 19:35
@giuseppe giuseppe force-pushed the improve-chunked-merge-heuristic branch from 631f5e8 to 5a50f39 Compare February 28, 2024 20:16
@giuseppe giuseppe marked this pull request as ready for review February 28, 2024 20:36
@giuseppe
Copy link
Member Author

@mtrmac @rhatdan PTAL

@rhatdan
Copy link
Member

rhatdan commented Feb 29, 2024

LGTM
@alexlarsson PTAL

@rhatdan
Copy link
Member

rhatdan commented Mar 1, 2024

@mtrmac @nalind @saschagrunert PTAL

Copy link
Contributor

openshift-ci bot commented Mar 1, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: giuseppe, saschagrunert

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:
  • OWNERS [giuseppe,saschagrunert]

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

Copy link
Collaborator

@mtrmac mtrmac left a comment

Choose a reason for hiding this comment

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

Locally LGTM (but I forgot all about how this works, if I ever knew, and I didn’t study what OriginFile/Hole/Chunks/… mean now.)

pkg/chunked/storage_linux.go Outdated Show resolved Hide resolved
pkg/chunked/storage_linux.go Outdated Show resolved Hide resolved
@giuseppe giuseppe force-pushed the improve-chunked-merge-heuristic branch from 5a50f39 to 70ce1c0 Compare March 1, 2024 16:08
improve the function that combines neighbor chunks.  Instead of using
the number of parts, which also includes local files, use only the
number of chunks that must be retrieved from the network.

In addition, introduce a threshold limit to merge chunks so that we
further reduce the number of requested ranges.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@giuseppe giuseppe force-pushed the improve-chunked-merge-heuristic branch from 70ce1c0 to 43b836e Compare March 1, 2024 16:09
Copy link
Collaborator

@mtrmac mtrmac left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Mar 1, 2024
@openshift-merge-bot openshift-merge-bot bot merged commit 7cd5d22 into containers:main Mar 1, 2024
6 of 18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants