File tree Expand file tree Collapse file tree 2 files changed +9
-11
lines changed Expand file tree Collapse file tree 2 files changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -98,7 +98,6 @@ describe('Cynosdb', () => {
98
98
connection : {
99
99
ip : expect . any ( String ) ,
100
100
port : 3306 ,
101
- readList : expect . any ( Array ) ,
102
101
} ,
103
102
} ) ;
104
103
@@ -123,7 +122,6 @@ describe('Cynosdb', () => {
123
122
connection : {
124
123
ip : expect . any ( String ) ,
125
124
port : 3306 ,
126
- readList : expect . any ( Array ) ,
127
125
} ,
128
126
publicConnection : {
129
127
domain : expect . any ( String ) ,
@@ -150,7 +148,6 @@ describe('Cynosdb', () => {
150
148
connection : {
151
149
ip : expect . any ( String ) ,
152
150
port : 3306 ,
153
- readList : expect . any ( Array ) ,
154
151
} ,
155
152
} ) ;
156
153
inputs . clusterId = undefined ;
Original file line number Diff line number Diff line change @@ -42,18 +42,19 @@ function isSupportZone(zone, isServerless = false) {
42
42
}
43
43
44
44
function formatConnectOutput ( detail ) {
45
- const RoAddr = detail . RoAddr || [ ] ;
46
- const readList = RoAddr . map ( ( item ) => {
47
- return {
48
- ip : item . IP ,
49
- port : item . Port ,
50
- } ;
51
- } ) ;
52
45
const info = {
53
46
ip : detail . Vip ,
54
47
port : detail . Vport ,
55
- readList : readList ,
56
48
} ;
49
+ if ( detail . DbMode !== 'SERVERLESS' ) {
50
+ const RoAddr = detail . RoAddr || [ ] ;
51
+ info . readList = RoAddr . map ( ( item ) => {
52
+ return {
53
+ ip : item . IP ,
54
+ port : item . Port ,
55
+ } ;
56
+ } ) ;
57
+ }
57
58
58
59
return info ;
59
60
}
You can’t perform that action at this time.
0 commit comments