containerd / accelerated-container-image

A production-ready remote container image format (overlaybd) and snapshotter based on block-device.
Apache License 2.0
405 stars 73 forks source link

Making background download block size configurable. #206

Closed shuaichang closed 1 year ago

shuaichang commented 1 year ago

What is the version of your Accelerated Container Image

0.6.7

What would you like to be added?

Making overlaybd background downloading request size (currently hardcoded to 256KB) to configurable.

Why is this needed for Accelerated Container Image?

It seems the background download with a fixed 256KB per request https://github.com/containerd/overlaybd/blob/279a7b3dac5c4105780cdce33218d2a359e6e5f4/src/bk_download.cpp#LL188C12-L188C14, which generates 10X number of requests compared to the requests from on-demand load (3-4X more data to download and the ondemand download is 1MB also resulted in less requests)

This behavior causes 2 major issues: a) cost increase to cloud object storage b) more likely to be throttled by cloud provider object storage.

Is it possible to make the request size of background downloading tunnable? We want to make it something like 10+MB per request to reduce QPS.

Thanks!

Are you willing to submit PRs to contribute to this feature?

yuchen0cc commented 1 year ago

Add this feature in https://github.com/containerd/overlaybd/pull/222

liulanzheng commented 1 year ago

https://github.com/containerd/overlaybd/pull/222

shuaichang commented 1 year ago

Thanks folks for the quick reply!