From f02d31aed8d80f8d0202fd8151f70bd98550af7b Mon Sep 17 00:00:00 2001 From: Paul Lorenz Date: Fri, 11 Mar 2022 13:20:17 -0500 Subject: [PATCH] Update deps and adjust for update channel API --- go.mod | 6 +++--- go.sum | 12 ++++++------ router/xgress_edge/factory.go | 2 +- router/xgress_edge/factory_test.go | 16 ++++++++-------- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/go.mod b/go.mod index 1dec46e2f..4831c1452 100644 --- a/go.mod +++ b/go.mod @@ -44,10 +44,10 @@ require ( github.com/miekg/dns v1.1.46 github.com/mitchellh/mapstructure v1.4.3 github.com/netfoundry/secretstream v0.1.2 - github.com/openziti/channel v0.18.14 - github.com/openziti/fabric v0.17.62 + github.com/openziti/channel v0.18.15 + github.com/openziti/fabric v0.17.63 github.com/openziti/foundation v0.17.8 - github.com/openziti/sdk-golang v0.16.20 + github.com/openziti/sdk-golang v0.16.21 github.com/orcaman/concurrent-map v0.0.0-20210106121528-16402b402231 github.com/pkg/errors v0.9.1 github.com/rcrowley/go-metrics v0.0.0-20200313005456-10cdbea86bc0 diff --git a/go.sum b/go.sum index 59b9c0557..38e0b4f85 100644 --- a/go.sum +++ b/go.sum @@ -688,15 +688,15 @@ github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je4 github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= github.com/openzipkin/zipkin-go v0.1.1/go.mod h1:NtoC/o8u3JlF1lSlyPNswIbeQH9bJTmOf0Erfk+hxe8= -github.com/openziti/channel v0.18.14 h1:MS6Wfo0BklKI/IQ/HQl+wKJBw9rPimTSSqFIeBcsHGQ= -github.com/openziti/channel v0.18.14/go.mod h1:F370DYbKEKpIEhRaZVbEK6xN+pirSZx4qnwbObQAV2I= +github.com/openziti/channel v0.18.15 h1:t5D/NBQMjOpoGrPlbuQRtyPoOWrRwk9ES5CNleFaJ7Y= +github.com/openziti/channel v0.18.15/go.mod h1:F370DYbKEKpIEhRaZVbEK6xN+pirSZx4qnwbObQAV2I= github.com/openziti/dilithium v0.3.3/go.mod h1:vsCjI2AU/hon9e+dLhUFbCNGesJDj2ASgkySOcpmvjo= -github.com/openziti/fabric v0.17.62 h1:V1Eavso4AvMSCMXJYtEATu5NQ9Dtpu3s3OYZt+SuVwY= -github.com/openziti/fabric v0.17.62/go.mod h1:8oBcmWriG/nTGF/+8pkv1oAKQY97XXG4ptns8dUTMr4= +github.com/openziti/fabric v0.17.63 h1:9uv6DdA271ypkB/74F/exsEZ0g5SUaUnF4TJcW8ckaY= +github.com/openziti/fabric v0.17.63/go.mod h1:ZfxlvTlHwLRJTmM4jGdyYsVm+Bd6RpnY3BgH8TJaJHM= github.com/openziti/foundation v0.17.8 h1:vlX6yQHrs5Tcp39xHylJhzohTDOZ6d/VrVlQahw7GBo= github.com/openziti/foundation v0.17.8/go.mod h1:dTaJgdO5OqnKpV+0OPHpnTnqfPpqNGbhJv8O6pMot6o= -github.com/openziti/sdk-golang v0.16.20 h1:AtSaD0Do5HgkDWFR0dLUVpiOpky2WAh6cf78hcG30jk= -github.com/openziti/sdk-golang v0.16.20/go.mod h1:uQ90QCehBrfO/xmpnWGVr3Jj65BMUrvGPH4I0gRl0og= +github.com/openziti/sdk-golang v0.16.21 h1:rIbw55mWzFZRXw12U9j7T8cKrJAxilzEFOCfU4NuemY= +github.com/openziti/sdk-golang v0.16.21/go.mod h1:0s6BUz7/R3Arn+RnrnqhDwOFgUcQdxdrPBC0lQevRUM= github.com/orcaman/concurrent-map v0.0.0-20190826125027-8c72a8bb44f6/go.mod h1:Lu3tH6HLW3feq74c2GC+jIMS/K2CFcDWnWD9XkenwhI= github.com/orcaman/concurrent-map v0.0.0-20210106121528-16402b402231 h1:fa50YL1pzKW+1SsBnJDOHppJN9stOEwS+CRWyUtyYGU= github.com/orcaman/concurrent-map v0.0.0-20210106121528-16402b402231/go.mod h1:Lu3tH6HLW3feq74c2GC+jIMS/K2CFcDWnWD9XkenwhI= diff --git a/router/xgress_edge/factory.go b/router/xgress_edge/factory.go index e3f54d785..17b3d6213 100644 --- a/router/xgress_edge/factory.go +++ b/router/xgress_edge/factory.go @@ -228,7 +228,7 @@ func (options *Options) ToLoggableString() string { buf.WriteString(fmt.Sprintf("lookupSessionTimeout=%v\n", options.lookupSessionTimeout)) buf.WriteString(fmt.Sprintf("channel.outQueueSize=%v\n", options.channelOptions.OutQueueSize)) - buf.WriteString(fmt.Sprintf("channel.connectTimeoutMs=%v\n", options.channelOptions.ConnectTimeoutMs)) + buf.WriteString(fmt.Sprintf("channel.connectTimeout=%v\n", options.channelOptions.ConnectTimeout)) buf.WriteString(fmt.Sprintf("channel.maxOutstandingConnects=%v\n", options.channelOptions.MaxOutstandingConnects)) buf.WriteString(fmt.Sprintf("channel.maxQueuedConnects=%v\n", options.channelOptions.MaxQueuedConnects)) diff --git a/router/xgress_edge/factory_test.go b/router/xgress_edge/factory_test.go index 7a2917dbe..aa155f2c6 100644 --- a/router/xgress_edge/factory_test.go +++ b/router/xgress_edge/factory_test.go @@ -44,8 +44,8 @@ func Test_load(t *testing.T) { require.New(t).Equal(connectMaxOutstandingConnects, options.channelOptions.MaxOutstandingConnects) }) - t.Run("has ConnectTimeoutMs value set", func(t *testing.T) { - require.New(t).Equal(connectTimeoutMs, options.channelOptions.ConnectTimeoutMs) + t.Run("has ConnectTimeout value set", func(t *testing.T) { + require.New(t).Equal(connectTimeout, options.channelOptions.ConnectTimeout) }) }) @@ -67,8 +67,8 @@ func Test_load(t *testing.T) { require.New(t).Equal(defaults.MaxOutstandingConnects, options.channelOptions.MaxOutstandingConnects) }) - t.Run("has ConnectTimeoutMs set to the default value", func(t *testing.T) { - require.New(t).Equal(defaults.ConnectTimeoutMs, options.channelOptions.ConnectTimeoutMs) + t.Run("has ConnectTimeout set to the default value", func(t *testing.T) { + require.New(t).Equal(defaults.ConnectTimeout, options.channelOptions.ConnectTimeout) }) }) @@ -93,11 +93,11 @@ func Test_load(t *testing.T) { require.New(t).Error(err) }) - t.Run("errors if ConnectTimeoutMs is invalid", func(t *testing.T) { + t.Run("errors if ConnectTimeout is invalid", func(t *testing.T) { options := &Options{} testConfig := newTestConfigWithoutConnectOptions() optionsConfig := testConfig["options"].(map[interface{}]interface{}) - optionsConfig["connectTimeoutMs"] = 0 + optionsConfig["connectTimeout"] = "abcded" err := options.load(testConfig) require.New(t).Error(err) @@ -108,7 +108,7 @@ func Test_load(t *testing.T) { const ( connectMaxQueuedConnections = 50 connectMaxOutstandingConnects = 100 - connectTimeoutMs = 1000 * time.Millisecond + connectTimeout = 1000 * time.Millisecond ) func newTestConfigWithConnectOptions() xgress.OptionsData { @@ -119,7 +119,7 @@ func newTestConfigWithConnectOptions() xgress.OptionsData { "advertise": "127.0.0.1:3022", "maxQueuedConnects": connectMaxQueuedConnections, "maxOutstandingConnects": connectMaxOutstandingConnects, - "connectTimeoutMs": connectTimeoutMs, + "connectTimeout": connectTimeout.String(), }, } }