containerd/integration
Wei Fu 00d102da9f feature: support image pull progress timeout
Kubelet sends the PullImage request without timeout, because the image size
is unknown and timeout is hard to defined. The pulling request might run
into 0B/s speed, if containerd can't receive any packet in that connection.
For this case, the containerd should cancel the PullImage request.

Although containerd provides ingester manager to track the progress of pulling
request, for example `ctr image pull` shows the console progress bar, it needs
more CPU resources to open/read the ingested files to get status.

In order to support progress timeout feature with lower overhead, this
patch uses http.RoundTripper wrapper to track active progress. That
wrapper will increase active-request number and return the
countingReadCloser wrapper for http.Response.Body. Each bytes-read
can be count and the active-request number will be descreased when the
countingReadCloser wrapper has been closed. For the progress tracker,
it can check the active-request number and bytes-read at intervals. If
there is no any progress, the progress tracker should cancel the
request.

NOTE: For each blob data, the containerd will make sure that the content
writer is opened before sending http request to the registry. Therefore, the
progress reporter can rely on the active-request number.

fixed: #4984

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2022-04-27 00:02:27 +08:00
..
client Merge pull request #6826 from kzys/ptypes 2022-04-19 10:13:56 -07:00
cri-api/pkg/apis feat: enable cri remote client to call with grpc calloptions 2021-09-30 23:02:53 +08:00
images integration/images/volume-ownership: strip path information from usage output 2022-01-31 21:07:00 +01:00
remote Use insecure.NewCredentials instead of grpc.WithInsecure 2021-12-16 23:10:06 +00:00
addition_gids_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
build_local_containerd_helper_test_linux.go feature: support image pull progress timeout 2022-04-27 00:02:27 +08:00
build_local_containerd_helper_test.go feature: support image pull progress timeout 2022-04-27 00:02:27 +08:00
common.go integration: align tags of test images 2021-12-03 15:14:09 +01:00
container_log_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
container_restart_test.go test integration: Adds a test that restarts a failed container 2021-06-25 10:33:38 +00:00
container_stats_test.go feat: replace github.com/pkg/errors to errors 2022-01-07 10:27:03 +08:00
container_stop_test.go Merge pull request #5619 from mikebrow/cri-add-v1-proxy-alpha 2021-07-09 14:07:24 -04:00
container_update_resources_test.go cri: fix integration test on cgroupsv2 system 2022-02-28 21:27:53 +08:00
container_volume_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
container_without_image_ref_test.go Merge pull request #5619 from mikebrow/cri-add-v1-proxy-alpha 2021-07-09 14:07:24 -04:00
containerd_image_test.go Replace golang.org/x/net/context with std library 2022-02-22 02:27:05 +08:00
duplicate_name_test.go tests: Refactors PodSandbox creation 2021-06-03 16:02:38 +00:00
image_list.sample.toml integration: align tags of test images 2021-12-03 15:14:09 +01:00
image_load_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
image_pull_timeout_test.go feature: support image pull progress timeout 2022-04-27 00:02:27 +08:00
imagefs_info_test.go feat: replace github.com/pkg/errors to errors 2022-01-07 10:27:03 +08:00
main_test.go CRI integration test for Windows Device mounts 2022-03-12 08:16:43 +11:00
no_metadata_test.go Merge pull request #5619 from mikebrow/cri-add-v1-proxy-alpha 2021-07-09 14:07:24 -04:00
pod_dualstack_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
pod_hostname_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
restart_test.go Replace golang.org/x/net/context with std library 2022-02-22 02:27:05 +08:00
runtime_handler_test.go integration: Enables TestRuntimeHandler for Windows 2021-10-07 18:20:59 -07:00
sandbox_clean_remove_test.go refactor: move from io/ioutil to io and os package 2021-09-21 09:50:38 +08:00
shim_dial_unix_test.go test: use T.TempDir to create temporary test directory 2022-03-15 14:03:50 +08:00
truncindex_test.go Adds Windows resource limits support 2021-09-25 13:20:55 -07:00
volume_copy_up_test.go remove io/ioutil 2022-01-11 16:07:23 +08:00
volume_copy_up_unix_test.go Replace find with native Go code 2021-12-07 11:04:38 +00:00
volume_copy_up_windows_test.go Replace find with native Go code 2021-12-07 11:04:38 +00:00
windows_device_test.go CRI integration test for Windows Device mounts 2022-03-12 08:16:43 +11:00
windows_hostprocess_test.go integration: Adds Windows HostProcess tests 2021-09-07 00:30:28 -07:00