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

Remove deprecated host-discovery and overlay networks with external k/v #42247

Merged
merged 15 commits into from
Jan 6, 2022

Conversation

thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Apr 2, 2021

closes #40383

currently vendoring libnetwork changes from moby/libnetwork#2521

- Description for the changelog

- A picture of a cute animal (not mandatory but encouraged)

@thaJeztah
Copy link
Member Author

Two tests failing that could be related

=== RUN   TestDockerDaemonSuite/TestDaemonICCLinkExpose
    --- FAIL: TestDockerDaemonSuite/TestDaemonICCLinkExpose (134.86s)
        docker_cli_daemon_test.go:909: assertion failed: error is not nil: exit status 1
=== RUN   TestDockerDaemonSuite/TestDaemonICCPing
    --- FAIL: TestDockerDaemonSuite/TestDaemonICCPing (7.99s)
        docker_cli_daemon_test.go:885: assertion failed: error is not nil: exit status 1: PING 192.171.1.1 (192.171.1.1): 56 data bytes
            
            --- 192.171.1.1 ping statistics ---
            1 packets transmitted, 0 packets received, 100% packet loss

@thaJeztah
Copy link
Member Author

thaJeztah commented Jun 28, 2021

[2021-06-28T10:25:56.637Z] libnetwork/controller.go:549:22: func `(*controller).activeCallback` is unused (unused)
[2021-06-28T10:25:56.638Z] libnetwork/controller.go:556:22: func `(*controller).hostJoinCallback` is unused (unused)
[2021-06-28T10:25:56.638Z] libnetwork/controller.go:560:22: func `(*controller).hostLeaveCallback` is unused (unused)
=== RUN   TestDockerDaemonSuite/TestDaemonICCLinkExpose
    docker_cli_daemon_test.go:908: assertion failed: error is not nil: exit status 1
    check_test.go:309: [deacc764e3b6f] daemon is not started
    --- FAIL: TestDockerDaemonSuite/TestDaemonICCLinkExpose (134.36s)
TestDockerDaemonSuite/TestDaemonICCPing
    docker_cli_daemon_test.go:864: [d9d50010d717e] failed to start daemon with arguments [--data-root /go/src/github.com/docker/docker/bundles/test-integration/TestDockerDaemonSuite/TestDaemonICCPing/d9d50010d717e/root --exec-root /tmp/dxr/d9d50010d717e --pidfile /go/src/github.com/docker/docker/bundles/test-integration/TestDockerDaemonSuite/TestDaemonICCPing/d9d50010d717e/docker.pid --userland-proxy=true --containerd-namespace d9d50010d717e --containerd-plugins-namespace d9d50010d717ep --containerd /var/run/docker/containerd/containerd.sock --host unix:///tmp/docker-integration/d9d50010d717e.sock --debug --storage-driver overlay2 --bridge external-bridge --iccdaemon.New=false] : [d9d50010d717e] daemon exited during startup: exit status 1
    check_test.go:309: [db5b083321b9c] daemon is not started
    --- FAIL: TestDockerDaemonSuite/TestDaemonICCPing (0.57s)

This part looks fishy; did I mess up a copy/paste? --iccdaemon.New=false

@errordeveloper
Copy link
Contributor

This part looks fishy; did I mess up a copy/paste? --iccdaemon.New=false

I think you meant --icc=false ;)

@@ -114,7 +114,7 @@ type ScopeClientCfg struct {
const (
// LocalScope indicates to store the KV object in local datastore such as boltdb
LocalScope = "local"
// GlobalScope indicates to store the KV object in global datastore such as etcd
// GlobalScope indicates to store the KV object in global datastore
GlobalScope = "global"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Possibly, this const (and its use) can also be removed, but leaving that for a separate PR (as it's used in quite some places)

"github.com/sirupsen/logrus"
)

func registerKVStores() {
etcd.Register()
boltdb.Register()
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also need to check if this store is actually used (I thought it was, because I know libnetwork uses boltdb for some things), but not sure if this code is actually used for that.

@thaJeztah thaJeztah changed the title [WIP] Remove deprecated host-discovery and overlay networks with external k/v Remove deprecated host-discovery and overlay networks with external k/v Dec 22, 2021
thaJeztah and others added 15 commits January 6, 2022 18:28
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Use unique names to prevent tests from interfering, using a shorter
name, as there's a maximum length for these.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Anca Iordache <anca.iordache@docker.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Based on randomLocalStore() in libnetwork/ipam/allocator_test.go

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Copy link
Member

@cpuguy83 cpuguy83 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@tianon tianon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment on lines 135 to 141
if [ "$nip" != "" ]; then
neighbors=${nip}
fi

discovery=""
provider=""
address=""
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This indentation is technically "wrong" now, but IMO it's not important enough to put this through CI/edits again (maybe something someone can fix as a separate PR).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, yeah, quite likely; I mostly tried to make my "remote X" commits clear on what I was removing, which I why I removed the bits that were related, but I think none of these are used anymore, so we likely can just remove everything here. now (I'll keep that for a follow-up)

@thaJeztah
Copy link
Member Author

okay, i'm gonna "YOLO" and bring this one in 🙈, then look at the follow-up rebasing to make the go.mod / vendor.mod work

Thanks for reviewing!! ❤️

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

Successfully merging this pull request may close these issues.

Proposal: deprecated (and remove) "--cluster-xx" options (legacy overlay networks)
5 participants