1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00
moby--moby/api/types
Josh Hawn 4921171587 Update ContainerWait API
This patch adds the untilRemoved option to the ContainerWait API which
allows the client to wait until the container is not only exited but
also removed.

This patch also adds some more CLI integration tests for waiting for a
created container and waiting with the new --until-removed flag.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Handle detach sequence in CLI

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Update Container Wait Conditions

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Apply container wait changes to API 1.30

The set of changes to the containerWait API missed the cut for the
Docker 17.05 release (API version 1.29). This patch bumps the version
checks to use 1.30 instead.

This patch also makes a minor update to a testfile which was added to
the builder/dockerfile package.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Remove wait changes from CLI

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Address minor nits on wait changes

- Changed the name of the tty Proxy wrapper to `escapeProxy`
- Removed the unnecessary Error() method on container.State
- Fixes a typo in comment (repeated word)

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Use router.WithCancel in the containerWait handler

This handler previously added this functionality manually but now uses
the existing wrapper which does it for us.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Add WaitCondition constants to api/types/container

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Address more ContainerWait review comments

- Update ContainerWait backend interface to not return pointer values
  for container.StateStatus type.
- Updated container state's Wait() method comments to clarify that a
  context MUST be used for cancelling the request, setting timeouts,
  and to avoid goroutine leaks.
- Removed unnecessary buffering when making channels in the client's
  ContainerWait methods.
- Renamed result and error channels in client's ContainerWait methods
  to clarify that only a single result or error value would be sent
  on the channel.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Move container.WaitCondition type to separate file

... to avoid conflict with swagger-generated code for API response

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)

Address more ContainerWait review comments

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
2017-05-16 15:11:39 -07:00
..
backend Refactor imageContexts into two different structs. 2017-05-10 17:59:30 -04:00
blkiodev
container Update ContainerWait API 2017-05-16 15:11:39 -07:00
events
filters use t.Fatal() to output the err message where the values used for formatting 2017-02-23 10:16:22 +08:00
image Set expected response headers for Ping. 2017-01-03 11:47:47 -05:00
mount Add 'consistent', 'cached', and 'delegated' mode flags 2017-03-01 18:13:47 +00:00
network Enhance network inspect to show all tasks, local & non-local, in swarm mode 2017-03-13 17:52:08 -07:00
plugins/logdriver Implement plugins for logging drivers 2017-04-10 13:17:20 -04:00
registry /distribution/{name}/json returns full Descriptor object 2017-05-09 17:25:27 -07:00
strslice
swarm Adding Platforms field to TaskSpec 2017-05-15 14:58:20 -07:00
time fix typo in api/types/time/timestamp.go 2017-01-14 14:16:03 +08:00
versions Merge pull request #28651 from YuPengZTE/devMD002 2016-11-22 13:11:37 +01:00
volume hack/swagger-gen.sh is not exist, it should be /hack/generate-swagger-api.sh 2016-11-22 16:32:32 +08:00
auth.go
client.go Merge pull request #28923 from erikh/fix-copy 2017-04-12 08:21:17 -07:00
configs.go Enforce zero plugin refcount during disable. 2016-12-22 13:26:53 -08:00
error_response.go
graph_driver_data.go Generate GraphDriver from spec, and fix up image spec. 2017-01-03 11:47:47 -05:00
id_response.go
image_delete_response_item.go Generate ImageDeleteResponse from swagger spec. 2017-01-03 11:47:47 -05:00
image_summary.go
plugin.go Embed DockerVersion in plugin config. 2017-03-22 10:26:20 -07:00
plugin_device.go
plugin_env.go
plugin_interface_type.go
plugin_mount.go
plugin_responses.go Rewrite the function 'validatePrivileges' without checking order 2017-02-04 08:47:40 +08:00
port.go
seccomp.go change minor mistake of spelling 2016-12-20 21:05:19 +08:00
service_update_response.go
stats.go Correct CPU usage calculation in presence of offline CPUs and newer Linux 2017-03-10 10:24:33 +00:00
types.go Add config APIs 2017-05-11 10:08:21 -07:00
volume.go