diff options
author | Neil Alexander <neilalexander@users.noreply.github.com> | 2021-10-22 11:38:04 +0100 |
---|---|---|
committer | Neil Alexander <neilalexander@users.noreply.github.com> | 2021-10-22 11:38:04 +0100 |
commit | 4c129e3e3d6e8d952a87f79d9fe6cb343e2de341 (patch) | |
tree | 0ce0131a4791aa6c7a446f0cbead2ee4d3d5eec8 /cmd | |
parent | 3b7a4ad640f260b3918a35684b05ced077a09f0c (diff) |
Update Pinecone demo
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/dendrite-demo-pinecone/conn/client.go | 2 | ||||
-rw-r--r-- | cmd/dendrite-demo-pinecone/main.go | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/cmd/dendrite-demo-pinecone/conn/client.go b/cmd/dendrite-demo-pinecone/conn/client.go index 5ba8e8ec..29436fda 100644 --- a/cmd/dendrite-demo-pinecone/conn/client.go +++ b/cmd/dendrite-demo-pinecone/conn/client.go @@ -34,7 +34,7 @@ func ConnectToPeer(pRouter *pineconeRouter.Router, peer string) error { if parent == nil { return fmt.Errorf("failed to wrap connection") } - _, err := pRouter.AuthenticatedConnect(parent, "static", pineconeRouter.PeerTypeRemote) + _, err := pRouter.AuthenticatedConnect(parent, "static", pineconeRouter.PeerTypeRemote, true) return err } diff --git a/cmd/dendrite-demo-pinecone/main.go b/cmd/dendrite-demo-pinecone/main.go index 7aa72632..60b83dc7 100644 --- a/cmd/dendrite-demo-pinecone/main.go +++ b/cmd/dendrite-demo-pinecone/main.go @@ -91,7 +91,7 @@ func main() { } logger := log.New(os.Stdout, "", 0) - pRouter := pineconeRouter.NewRouter(logger, sk, "dendrite", nil) + pRouter := pineconeRouter.NewRouter(logger, sk, false) go func() { listener, err := net.Listen("tcp", *instanceListen) @@ -108,7 +108,7 @@ func main() { continue } - port, err := pRouter.AuthenticatedConnect(conn, "", pineconeRouter.PeerTypeRemote) + port, err := pRouter.AuthenticatedConnect(conn, "", pineconeRouter.PeerTypeRemote, true) if err != nil { logrus.WithError(err).Error("pSwitch.AuthenticatedConnect failed") continue @@ -231,7 +231,7 @@ func main() { return } conn := conn.WrapWebSocketConn(c) - if _, err = pRouter.AuthenticatedConnect(conn, "websocket", pineconeRouter.PeerTypeRemote); err != nil { + if _, err = pRouter.AuthenticatedConnect(conn, "websocket", pineconeRouter.PeerTypeRemote, true); err != nil { logrus.WithError(err).Error("Failed to connect WebSocket peer to Pinecone switch") } }) |