11//
22// DISCLAIMER
33//
4- // Copyright 2016-2024 ArangoDB GmbH, Cologne, Germany
4+ // Copyright 2016-2025 ArangoDB GmbH, Cologne, Germany
55//
66// Licensed under the Apache License, Version 2.0 (the "License");
77// you may not use this file except in compliance with the License.
@@ -27,7 +27,7 @@ import (
2727 "fmt"
2828 "io"
2929 "net"
30- "net/http"
30+ goHttp "net/http"
3131 "os"
3232 "os/signal"
3333 "strconv"
@@ -169,11 +169,11 @@ func cmdGetAgencyDump(cmd *cobra.Command, _ []string) {
169169func getAgencyState (ctx context.Context , conn connection.Connection ) (io.ReadCloser , error ) {
170170 url := connection .NewUrl ("_api" , "agency" , "read" )
171171 data := []byte (`[["/"]]` )
172- resp , body , err := connection .CallStream (ctx , conn , http .MethodPost , url , connection .WithBody (data ))
172+ resp , body , err := connection .CallStream (ctx , conn , goHttp .MethodPost , url , connection .WithBody (data ))
173173 if err != nil {
174174 return nil , err
175175 }
176- if resp .Code () != http .StatusOK {
176+ if resp .Code () != goHttp .StatusOK {
177177 return nil , errors .New (fmt .Sprintf ("unexpected HTTP status from \" %s\" endpoint" , url ))
178178 }
179179
@@ -241,7 +241,7 @@ func getAgencyLeader(ctx context.Context, conn connection.Connection) (string, e
241241 if err != nil {
242242 return "" , err
243243 }
244- if resp .Code () != http .StatusOK {
244+ if resp .Code () != goHttp .StatusOK {
245245 return "" , errors .New ("unexpected HTTP status from agency-dump endpoint" )
246246 }
247247
@@ -257,11 +257,11 @@ func getAgencyLeader(ctx context.Context, conn connection.Connection) (string, e
257257// getAgencyDump returns dump of the agency.
258258func getAgencyDump (ctx context.Context , conn connection.Connection ) (io.ReadCloser , error ) {
259259 url := connection .NewUrl ("_api" , "cluster" , "agency-dump" )
260- resp , body , err := connection .CallStream (ctx , conn , http .MethodGet , url )
260+ resp , body , err := connection .CallStream (ctx , conn , goHttp .MethodGet , url )
261261 if err != nil {
262262 return nil , err
263263 }
264- if resp .Code () != http .StatusOK {
264+ if resp .Code () != goHttp .StatusOK {
265265 return nil , errors .New ("unexpected HTTP status from agency-dump endpoint" )
266266 }
267267
@@ -285,7 +285,7 @@ func createClient(endpoints []string, certCA *x509.CertPool, auth connection.Aut
285285 Authentication : auth ,
286286 ContentType : contentType ,
287287 Endpoint : connection .NewRoundRobinEndpoints (endpoints ),
288- Transport : & http .Transport {
288+ Transport : & goHttp .Transport {
289289 TLSClientConfig : & tls.Config {
290290 RootCAs : certCA ,
291291 },
0 commit comments