spiegel_podman/pkg/bindings/images
Moritz "WanzenBug" Wanzenböck 5df883e87d bindings: reuse context for API requests
One of the main uses of context.Context is to provide cancellation for
go-routines, including API requests. While all user-facing bindings
already used a context parameter, it was only used to pass the client
information around.

This commit changes the internal DoRequest wrapper to take an additional
context argument, and pass that to the http request. Previously, the context
was derived from context.Background(), which made it impossible to cancel
once started.

All the convenience wrappers already supported the context parameter, so the
only user facing change is that cancelling those context now works as one
would expect.

Signed-off-by: Moritz "WanzenBug" Wanzenböck <moritz@wanzenbug.xyz>
2021-11-15 15:42:39 +01:00
..
build.go bindings: reuse context for API requests 2021-11-15 15:42:39 +01:00
build_test.go build: improve regex for iidfile 2021-05-06 11:33:59 +02:00
build_unix.go Handle hard links in remote builds 2021-05-22 05:27:03 -04:00
build_windows.go Handle hard links in remote builds 2021-05-22 05:27:03 -04:00
diff.go bindings: reuse context for API requests 2021-11-15 15:42:39 +01:00
images.go bindings: reuse context for API requests 2021-11-15 15:42:39 +01:00
pull.go bindings: reuse context for API requests 2021-11-15 15:42:39 +01:00
rm.go bindings: reuse context for API requests 2021-11-15 15:42:39 +01:00
types.go Refactor podman search to be more code friendly 2021-10-12 09:30:40 -07:00
types_diff_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_exists_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_export_options.go podman save: add --uncompressed 2021-09-22 12:38:07 +02:00
types_get_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_history_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_import_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_list_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_load_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_prune_options.go image prune: support removing external containers 2021-09-28 10:24:16 +02:00
types_pull_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_push_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_remove_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_search_options.go Refactor podman search to be more code friendly 2021-10-12 09:30:40 -07:00
types_tag_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_tree_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00
types_untag_options.go Enhance bindings for IDE hints 2021-09-14 07:47:24 -07:00