File tree 4 files changed +6
-3
lines changed
4 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -16,12 +16,12 @@ package common
16
16
17
17
import (
18
18
"context"
19
- "github.com/dubbo/go-for-apache-dubbo/common/constant"
20
19
"net/url"
21
20
"testing"
22
21
)
23
22
24
23
import (
24
+ "github.com/dubbo/go-for-apache-dubbo/common/constant"
25
25
"github.com/stretchr/testify/assert"
26
26
)
27
27
Original file line number Diff line number Diff line change 1
1
package utils
2
2
3
3
import (
4
- "github.com/stretchr/testify/assert"
5
4
"testing"
6
5
)
6
+ import (
7
+ "github.com/stretchr/testify/assert"
8
+ )
7
9
8
10
func Test_RegSplit (t * testing.T ) {
9
11
strings := RegSplit ("dubbo://123.1.2.1;jsonrpc://127.0.0.1;registry://3.2.1.3?registry=zookeeper" , "\\ s*[;]+\\ s*" )
Original file line number Diff line number Diff line change @@ -109,7 +109,7 @@ func (refconfig *ReferenceConfig) Refer() {
109
109
refconfig .invoker = extension .GetProtocol (refconfig .urls [0 ].Protocol ).Refer (* refconfig .urls [0 ])
110
110
} else {
111
111
invokers := []protocol.Invoker {}
112
- var regUrl * common.URL = nil
112
+ var regUrl * common.URL
113
113
for _ , u := range refconfig .urls {
114
114
invokers = append (invokers , extension .GetProtocol (u .Protocol ).Refer (* u ))
115
115
if u .Protocol == constant .REGISTRY_PROTOCOL {
Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ references:
38
38
filter : " "
39
39
protocol : " dubbo"
40
40
interface : " com.ikurento.user.UserProvider"
41
+ url : " dubbo://127.0.0.1:20000"
41
42
cluster : " failover"
42
43
methods :
43
44
- name : " GetUser"
You can’t perform that action at this time.
0 commit comments