The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/6132

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
This is a small tweak in the go-dqlite API, which helps decoupling a few things internally.

Signed-off-by: Free Ekanayaka <free.ekanay...@canonical.com>
From 91ea3ff6da80721478d7189f5f7d274fb371ab6d Mon Sep 17 00:00:00 2001
From: Free Ekanayaka <free.ekanay...@canonical.com>
Date: Wed, 28 Aug 2019 09:06:38 +0200
Subject: [PATCH] Adapt to changed dqlite.New() signature, not requiring
 NodeInfo anymore

Signed-off-by: Free Ekanayaka <free.ekanay...@canonical.com>
---
 lxd/cluster/gateway.go | 3 ++-
 lxd/db/testing.go      | 3 +--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/lxd/cluster/gateway.go b/lxd/cluster/gateway.go
index 13ce49aad8..1b83722abb 100644
--- a/lxd/cluster/gateway.go
+++ b/lxd/cluster/gateway.go
@@ -614,7 +614,8 @@ func (g *Gateway) init() error {
                }
 
                server, err := dqlite.New(
-                       raft.info,
+                       raft.info.ID,
+                       raft.info.Address,
                        dir,
                        options...,
                )
diff --git a/lxd/db/testing.go b/lxd/db/testing.go
index 8ed351af2f..8b5fae4ab5 100644
--- a/lxd/db/testing.go
+++ b/lxd/db/testing.go
@@ -115,9 +115,8 @@ func NewTestDqliteServer(t *testing.T) (string, 
driver.NodeStore, func()) {
        err = os.Mkdir(filepath.Join(dir, "global"), 0755)
        require.NoError(t, err)
 
-       info := driver.NodeInfo{ID: uint64(1), Address: address}
        server, err := dqlite.New(
-               info, filepath.Join(dir, "global"), 
dqlite.WithBindAddress(address))
+               uint64(1), address, filepath.Join(dir, "global"), 
dqlite.WithBindAddress(address))
        require.NoError(t, err)
 
        err = server.Start()
_______________________________________________
lxc-devel mailing list
lxc-devel@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to