@@ -85,7 +85,7 @@ func TestAPIEndpoints(t *testing.T) {
8585 })
8686
8787 // Before we disable recoveries, let us wait until VTOrc has fixed all the issues (if any).
88- _ , _ = utils .MakeAPICallRetry (t , vtorc , "/api/replication -analysis" , func (_ int , response string ) bool {
88+ _ , _ = utils .MakeAPICallRetry (t , vtorc , "/api/detection -analysis" , func (i int , response string ) bool {
8989 return response != "null"
9090 })
9191
@@ -164,41 +164,41 @@ func TestAPIEndpoints(t *testing.T) {
164164 assert .Equal (t , "Global recoveries disabled\n " , resp )
165165 })
166166
167- t .Run ("Replication Analysis API" , func (t * testing.T ) {
167+ t .Run ("Detection Analysis API" , func (t * testing.T ) {
168168 // use vtctldclient to stop replication
169169 _ , err := clusterInfo .ClusterInstance .VtctldClientProcess .ExecuteCommandWithOutput ("StopReplication" , replica .Alias )
170170 require .NoError (t , err )
171171
172172 // We know VTOrc won't fix this since we disabled global recoveries!
173173 // Wait until VTOrc picks up on this issue and verify
174- // that we see a not null result on the api/replication -analysis page
175- status , resp := utils .MakeAPICallRetry (t , vtorc , "/api/replication -analysis" , func (_ int , response string ) bool {
174+ // that we see a not null result on the api/detection -analysis page
175+ status , resp := utils .MakeAPICallRetry (t , vtorc , "/api/detection -analysis" , func (_ int , response string ) bool {
176176 return response == "null"
177177 })
178178 assert .Equal (t , 200 , status , resp )
179179 assert .Contains (t , resp , fmt .Sprintf (`"AnalyzedInstanceAlias": "%s"` , replica .Alias ))
180180 assert .Contains (t , resp , `"Analysis": "ReplicationStopped"` )
181181
182182 // Verify that filtering also works in the API as intended
183- status , resp , err = utils .MakeAPICall (t , vtorc , "/api/replication -analysis?keyspace=ks&shard=0" )
183+ status , resp , err = utils .MakeAPICall (t , vtorc , "/api/detection -analysis?keyspace=ks&shard=0" )
184184 require .NoError (t , err )
185185 assert .Equal (t , 200 , status , resp )
186186 assert .Contains (t , resp , fmt .Sprintf (`"AnalyzedInstanceAlias": "%s"` , replica .Alias ))
187187
188188 // Verify that filtering by keyspace also works in the API as intended
189- status , resp , err = utils .MakeAPICall (t , vtorc , "/api/replication -analysis?keyspace=ks" )
189+ status , resp , err = utils .MakeAPICall (t , vtorc , "/api/detection -analysis?keyspace=ks" )
190190 require .NoError (t , err )
191191 assert .Equal (t , 200 , status , resp )
192192 assert .Contains (t , resp , fmt .Sprintf (`"AnalyzedInstanceAlias": "%s"` , replica .Alias ))
193193
194194 // Check that filtering using keyspace and shard works
195- status , resp , err = utils .MakeAPICall (t , vtorc , "/api/replication -analysis?keyspace=ks&shard=80-" )
195+ status , resp , err = utils .MakeAPICall (t , vtorc , "/api/detection -analysis?keyspace=ks&shard=80-" )
196196 require .NoError (t , err )
197197 assert .Equal (t , 200 , status , resp )
198198 assert .Equal (t , "null" , resp )
199199
200200 // Check that filtering using just the shard fails
201- status , resp , err = utils .MakeAPICall (t , vtorc , "/api/replication -analysis?shard=0" )
201+ status , resp , err = utils .MakeAPICall (t , vtorc , "/api/detection -analysis?shard=0" )
202202 require .NoError (t , err )
203203 assert .Equal (t , 400 , status , resp )
204204 assert .Equal (t , "Filtering by shard without keyspace isn't supported\n " , resp )
0 commit comments