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

Make experimental a runtime flag #27223

Merged
merged 1 commit into from Oct 24, 2016
Merged

Conversation

@mlaventure
Copy link
Contributor

@mlaventure mlaventure commented Oct 7, 2016

Signed-off-by: Kenfe-Mickael Laventure mickael.laventure@gmail.com

Left to do:

  • Update the install script to automatically set "experimental": true if fetched from https://experimental.docker.com/
  • See what solution is adopted by #25498 and piggy back on it to check the daemon experimental flag
  • Update documentation

Closes #26713

@mlaventure mlaventure force-pushed the mlaventure:merge-experimental branch 3 times, most recently from 1cf6f42 to 6ed62b5 Oct 7, 2016
if experimentalDaemon {
args = append(args, "--experimental")
}
err := d.StartWithBusybox(args...) // avoid networking conflicts

This comment has been minimized.

@AkihiroSuda

AkihiroSuda Oct 13, 2016
Member

nit: IMO the comment should be moved to L267

This comment has been minimized.

@mlaventure

mlaventure Oct 14, 2016
Author Contributor

Updated, thanks.

@mlaventure mlaventure force-pushed the mlaventure:merge-experimental branch 5 times, most recently from bba1b28 to da64999 Oct 13, 2016
@icecrime
Copy link
Contributor

@icecrime icecrime commented Oct 17, 2016

See what solution is adopted by #25498 and piggy back on it to check the daemon experimental flag

I think it's perfectly fine to rely on /info in the meantime (we're just talking about optimizations here). Nevermind, Swarm-mode makes this potentially slow.

Otherwise design LGTM 👍

@icecrime
Copy link
Contributor

@icecrime icecrime commented Oct 19, 2016

See what solution is adopted by #25498 and piggy back on it to check the daemon experimental flag

This is a requirement, but it won't change much about this PR, so I'm moving it to code review so we can try and get it in for 1.13.0.

@justincormack
Copy link
Contributor

@justincormack justincormack commented Oct 20, 2016

This seems to be working as expected, code looks fine.

LGTM

@LK4D4
Copy link
Contributor

@LK4D4 LK4D4 commented Oct 20, 2016

LGTM
@mlaventure but need rebase

@mlaventure mlaventure force-pushed the mlaventure:merge-experimental branch 2 times, most recently from ec36188 to f522adf Oct 20, 2016
@@ -96,8 +96,7 @@ set -e
# Install runc and containerd
RUN ./hack/dockerfile/install-binaries.sh runc-dynamic containerd-dynamic
EOF

if [ "$DOCKER_EXPERIMENTAL" ]; then
if [[ "$VERSION" == *-dev ]] || [ -n "$(git status --porcelain)" ]; then
echo 'ENV DOCKER_EXPERIMENTAL 1' >> "$DEST/$version/Dockerfile.build"
fi

This comment has been minimized.

@tianon

tianon Oct 20, 2016
Member

Shouldn't this block just be removed completely, as in build-deb?

This comment has been minimized.

@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Oct 20, 2016

We should have a CI check or label to prevent future PR's from adding an experimental build-flag

/cc @ehazlett @mlaventure

@@ -1,4 +1,4 @@
// +build experimental
// +build !windows

This comment has been minimized.

@tianon

tianon Oct 20, 2016
Member

Were we just never running tests on windows with experimental enabled previously?

This comment has been minimized.

@mlaventure

mlaventure Oct 20, 2016
Author Contributor

Correct, all the test have DaemonIsLinux as a prerequisite

if [ "$DOCKER_EXPERIMENTAL" ]; then
echo >&2 '# DOCKER_EXPERIMENTAL is set: starting daemon with experimental features enabled! '
extra_params="$extra_params --experimental"
fi

This comment has been minimized.

@tianon

tianon Oct 20, 2016
Member

Aren't the experimental features tested regardless of whether this is set on our integration daemon, or does this mean we'll still need to run the full test suite twice (once without and once with this set)?

This comment has been minimized.

@mlaventure

mlaventure Oct 20, 2016
Author Contributor

Without it the experimental endpoint are not "exposed" to the clients.

However, if there''s code elsewhere that is supposed to be experimental and isn't guard by the proper check, testing both with and without the flag should help catch it.

@mlaventure mlaventure force-pushed the mlaventure:merge-experimental branch from f522adf to 71147c5 Oct 20, 2016
@vieux
vieux approved these changes Oct 24, 2016
Copy link
Contributor

@vieux vieux left a comment

LGTM

@ehazlett
Copy link
Contributor

@ehazlett ehazlett commented Oct 24, 2016

@docker/core-machine-maintainers machine will need some updates to support the new experimental flag.

LGTM

@@ -157,7 +157,7 @@ This section lists each version from latest to oldest. Each listing includes a
* `POST /containers/prune` prunes stopped containers.
* `POST /images/prune` prunes unused images.
* `POST /volumes/prune` prunes unused volumes.

* Every API response will now include a `Docker-Experimental` specifying if experimental feature are enabled (value can be `true` or `false`).

This comment has been minimized.

@thaJeztah

thaJeztah Oct 24, 2016
Member

Missing "header", I guess?

Every API response now includes a `Docker-Experimental` header specifying if 
experimental features are enabled (value can be `true` or `false`).
@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Oct 24, 2016

Had one small nit on docs, but feel free to go ahead if you prefer

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
@mlaventure mlaventure force-pushed the mlaventure:merge-experimental branch from 5d3eebb to 7781a1b Oct 24, 2016
@mlaventure
Copy link
Contributor Author

@mlaventure mlaventure commented Oct 24, 2016

@thaJeztah made the doc change.

Copy link
Member

@thaJeztah thaJeztah left a comment

LGTM

@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Oct 24, 2016

all green!

@thaJeztah thaJeztah merged commit ba41a5e into moby:master Oct 24, 2016
4 checks passed
4 checks passed
@GordonTheTurtle
docker/dco-signed All commits signed
Details
@GordonTheTurtle
experimental Jenkins build Docker-PRs-experimental 25332 has succeeded
Details
@GordonTheTurtle
janky Jenkins build Docker-PRs 33933 has succeeded
Details
@GordonTheTurtle
windowsRS1 Jenkins build Docker-PRs-WoW-RS1 4799 has succeeded
Details
@mlaventure mlaventure deleted the mlaventure:merge-experimental branch Oct 25, 2016
@thaJeztah thaJeztah mentioned this pull request Nov 6, 2016
2 of 4 tasks complete
tianon added a commit to tianon/jenkins-groovy that referenced this pull request Nov 14, 2016
@tianon
Copy link
Member

@tianon tianon commented Dec 14, 2016

https://github.com/docker/docker/blob/master/experimental/README.md should probably be updated for this change as well, right?

@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Dec 14, 2016

@tianon see #28160 ❤️

@praving55
Copy link

@praving55 praving55 commented Jan 19, 2017

Can you point me to the reference please? I could not see it in docs

@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Jan 19, 2017

docs for 1.13 are not yet published, but the flag itself is documented in the dockerd reference. You can either set a --experimental flag on the daemon (but depends on what init system (upstart, sysv-init, systemd) you're using, or use a daemon.json configuration file, as described here; https://github.com/docker/docker/blob/v1.13.0/docs/reference/commandline/dockerd.md#daemon-configuration-file

@praving55
Copy link

@praving55 praving55 commented Jan 19, 2017

Is there a reason docs are lagging? I never saw that happening before.

@thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Jan 19, 2017

Not all parts of the release are released yet, so the release will be officially announced after all projects have finished their release, and the docs will probably go out together with that.

@tuxity tuxity mentioned this pull request Jan 19, 2017
3 of 5 tasks complete
@praving55
Copy link

@praving55 praving55 commented Jan 19, 2017

ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment