From eb751e9ff76be774c76415852ed5d995d60608d9 Mon Sep 17 00:00:00 2001 From: atye Date: Fri, 2 Sep 2022 14:59:44 -0400 Subject: [PATCH 1/3] update gopowermax and support unisphere 10 and 9 --- cmd/karavictl/cmd/role.go | 5 ++--- cmd/karavictl/cmd/storage_create.go | 6 +++--- go.mod | 2 +- go.sum | 2 ++ internal/proxy/powermax_handler.go | 10 +++++----- internal/role-service/validate/powermax.go | 4 ++-- internal/storage-service/validate/powermax.go | 4 ++-- 7 files changed, 17 insertions(+), 16 deletions(-) diff --git a/cmd/karavictl/cmd/role.go b/cmd/karavictl/cmd/role.go index 79e81b66..3b08a02e 100644 --- a/cmd/karavictl/cmd/role.go +++ b/cmd/karavictl/cmd/role.go @@ -33,7 +33,7 @@ import ( "time" pscale "github.com/dell/goisilon" - pmax "github.com/dell/gopowermax" + pmax "github.com/dell/gopowermax/v2" "github.com/dell/goscaleio" "github.com/spf13/cobra" "google.golang.org/grpc" @@ -212,8 +212,7 @@ func validatePowerMaxStorageResourcePool(ctx context.Context, storageSystemDetai } epURL.Scheme = "https" - //TODO(aaron): how should the version (90, 91) be determined? - powerMaxClient, err := pmax.NewClientWithArgs(epURL.String(), "", "", true, false) + powerMaxClient, err := pmax.NewClientWithArgs(epURL.String(), "CSM-Authz", true, false) if err != nil { return err } diff --git a/cmd/karavictl/cmd/storage_create.go b/cmd/karavictl/cmd/storage_create.go index 8cdaf242..d72247a7 100644 --- a/cmd/karavictl/cmd/storage_create.go +++ b/cmd/karavictl/cmd/storage_create.go @@ -28,8 +28,8 @@ import ( "syscall" pscale "github.com/dell/goisilon" - pmax "github.com/dell/gopowermax" - "github.com/dell/gopowermax/types/v90" + pmax "github.com/dell/gopowermax/v2" + types "github.com/dell/gopowermax/v2/types/v100" "github.com/dell/goscaleio" "github.com/spf13/cobra" "sigs.k8s.io/yaml" @@ -272,7 +272,7 @@ func NewStorageCreateCmd() *cobra.Command { tempStorage = make(map[string]System) } - pmClient, err := pmax.NewClientWithArgs(epURL.String(), "", "karavi-auth", true, false) + pmClient, err := pmax.NewClientWithArgs(epURL.String(), "CSM-Authz", true, false) if err != nil { errAndExit(err) } diff --git a/go.mod b/go.mod index 580e405c..22793840 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,6 @@ go 1.18 require ( github.com/alicebob/miniredis/v2 v2.17.0 github.com/dell/goisilon v1.8.0 - github.com/dell/gopowermax v1.8.0 github.com/dell/goscaleio v1.7.0 github.com/dustin/go-humanize v1.0.0 github.com/fsnotify/fsnotify v1.5.1 @@ -42,6 +41,7 @@ require ( require ( github.com/beorn7/perks v1.0.1 // indirect github.com/cespare/xxhash/v2 v2.1.2 // indirect + github.com/dell/gopowermax/v2 v2.0.0-20220818034616-a85ab3cf9394 // indirect github.com/evanphx/json-patch v4.12.0+incompatible // indirect github.com/go-logr/stdr v1.2.0 // indirect github.com/golang/protobuf v1.5.2 // indirect diff --git a/go.sum b/go.sum index b52cbbf7..9fb78a21 100644 --- a/go.sum +++ b/go.sum @@ -145,6 +145,8 @@ github.com/dell/goisilon v1.8.0 h1:3CBNKCQMAqyJ8Qz3GiwCHIs2ds1Ur0trSnmR/hBKDX0= github.com/dell/goisilon v1.8.0/go.mod h1:fJXHyh1JBcbsmPBquEulaNOFTpj1eEN5vISDf/UY1RQ= github.com/dell/gopowermax v1.8.0 h1:Et02IZjkCTfjUL8vTCmX0pL18hBs54u1ygIuxbpo3zI= github.com/dell/gopowermax v1.8.0/go.mod h1:rwP7E76NKKl2C+adKe8rDbyfQX4VW041bFbpY0oAKM0= +github.com/dell/gopowermax/v2 v2.0.0-20220818034616-a85ab3cf9394 h1:OJD9eBFRJxTaEx8+tQrCRn4oJssmXTukzzWNsXcXYBw= +github.com/dell/gopowermax/v2 v2.0.0-20220818034616-a85ab3cf9394/go.mod h1:eJEsDN0O0nFqiSdgOXZK73Cv/LlP/+psnkyFSXLR/wI= github.com/dell/goscaleio v1.7.0 h1:ahc4L2TjrT931WdbuZahUmccuyZMdKbijbTRRvQVBBY= github.com/dell/goscaleio v1.7.0/go.mod h1:TJbQ8N6hk48w5rEyBa+pRtrRJbPVnCTsYM3mmUyPNaY= github.com/denisenkom/go-mssqldb v0.0.0-20200428022330-06a60b6afbbc/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU= diff --git a/internal/proxy/powermax_handler.go b/internal/proxy/powermax_handler.go index 9664b14e..3034f512 100644 --- a/internal/proxy/powermax_handler.go +++ b/internal/proxy/powermax_handler.go @@ -32,7 +32,7 @@ import ( "strings" "sync" - pmax "github.com/dell/gopowermax" + pmax "github.com/dell/gopowermax/v2" "github.com/julienschmidt/httprouter" "github.com/sirupsen/logrus" @@ -157,10 +157,10 @@ func (h *PowerMaxHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { router := httprouter.New() router.Handler(http.MethodPut, - "/univmax/restapi/91/sloprovisioning/symmetrix/:systemid/storagegroup/:storagegroup/", + "/univmax/restapi/:version/sloprovisioning/symmetrix/:systemid/storagegroup/:storagegroup/", v.editStorageGroupHandler(proxyHandler, h.enforcer, h.opaHost)) router.Handler(http.MethodPut, - "/univmax/restapi/91/sloprovisioning/symmetrix/:systemid/volume/:volumeid/", + "/univmax/restapi/:version/sloprovisioning/symmetrix/:systemid/volume/:volumeid/", v.volumeModifyHandler(proxyHandler, h.enforcer, h.opaHost)) router.NotFound = proxyHandler router.MethodNotAllowed = proxyHandler @@ -352,7 +352,7 @@ func (s *PowerMaxSystem) volumeCreateHandler(next http.Handler, enf *quota.Redis volID := payload.Editstoragegroupactionparam.Expandstoragegroupparam.Addvolumeparam.Volumeattributes[0].Volumeidentifier.IdentifierName // Determine which pool this SG exists within, as it will form the quota key. - client, err := pmax.NewClientWithArgs(s.Endpoint, pmax.APIVersion91, "CSMAuthz", true, false) + client, err := pmax.NewClientWithArgs(s.Endpoint, appName, true, false) if err != nil { writeError(w, "powermax", "failed to build powermax client", http.StatusInternalServerError, s.log) return @@ -568,7 +568,7 @@ func (s *PowerMaxSystem) volumeModifyHandler(next http.Handler, enf *quota.Redis } // Determine which pool this SG exists within, as it will form the quota key. - client, err := pmax.NewClientWithArgs(s.Endpoint, pmax.APIVersion91, appName, true, false) + client, err := pmax.NewClientWithArgs(s.Endpoint, appName, true, false) if err != nil { writeError(w, "powermax", "failed to build powermax client", http.StatusInternalServerError, s.log) return diff --git a/internal/role-service/validate/powermax.go b/internal/role-service/validate/powermax.go index 1d3870e0..0f1f49e0 100644 --- a/internal/role-service/validate/powermax.go +++ b/internal/role-service/validate/powermax.go @@ -21,7 +21,7 @@ import ( "karavi-authorization/internal/types" "net/url" - pmax "github.com/dell/gopowermax" + pmax "github.com/dell/gopowermax/v2" "github.com/sirupsen/logrus" ) @@ -53,7 +53,7 @@ func PowerMax(ctx context.Context, log *logrus.Entry, system types.System, syste }).Debug("Establishing connection to PowerMax") epURL.Scheme = "https" - powerMaxClient, err := pmax.NewClientWithArgs(epURL.String(), "", "", true, false) + powerMaxClient, err := pmax.NewClientWithArgs(epURL.String(), "CSM-Authz", true, false) if err != nil { return err } diff --git a/internal/storage-service/validate/powermax.go b/internal/storage-service/validate/powermax.go index f6666b87..1ce75680 100644 --- a/internal/storage-service/validate/powermax.go +++ b/internal/storage-service/validate/powermax.go @@ -20,7 +20,7 @@ import ( "karavi-authorization/internal/types" "net/url" - pmax "github.com/dell/gopowermax" + pmax "github.com/dell/gopowermax/v2" "github.com/sirupsen/logrus" ) @@ -39,7 +39,7 @@ func PowerMax(ctx context.Context, log *logrus.Entry, system types.System, syste } epURL.Scheme = "https" - powerMaxClient, err := pmax.NewClientWithArgs(epURL.String(), "", "", true, false) + powerMaxClient, err := pmax.NewClientWithArgs(epURL.String(), "CSM-Authz", true, false) if err != nil { return err } From ed7a98911b10dc2b2982fd250b778dac7f0b7f92 Mon Sep 17 00:00:00 2001 From: atye Date: Fri, 2 Sep 2022 16:06:52 -0400 Subject: [PATCH 2/3] fix tests --- cmd/karavictl/cmd/role_create_test.go | 6 +++--- cmd/karavictl/cmd/storage_create_test.go | 16 ++++++++-------- ...phere_api_types_System_instances_testing.json | 4 +--- internal/proxy/powermax_handler_test.go | 8 ++++---- internal/role-service/validate/validate_test.go | 12 ++++++------ .../storage-service/validate/validate_test.go | 4 ++-- 6 files changed, 24 insertions(+), 26 deletions(-) diff --git a/cmd/karavictl/cmd/role_create_test.go b/cmd/karavictl/cmd/role_create_test.go index adaa6324..47a5faac 100644 --- a/cmd/karavictl/cmd/role_create_test.go +++ b/cmd/karavictl/cmd/role_create_test.go @@ -171,9 +171,9 @@ func Test_Unit_RoleCreate_PowerMax(t *testing.T) { ts := httptest.NewTLSServer( http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { - case "/univmax/restapi/90/system/version": - fmt.Fprintf(w, `{ "version": "V9.2.1.2"}`) - case "/univmax/restapi/90/sloprovisioning/symmetrix/000197900714/srp/bronze": + case "/univmax/restapi/version": + fmt.Fprintf(w, `{ "version": "V10.0.0.1"}`) + case "/univmax/restapi/100/sloprovisioning/symmetrix/000197900714/srp/bronze": w.WriteHeader(http.StatusOK) default: t.Errorf("unhandled unisphere request path: %s", r.URL.Path) diff --git a/cmd/karavictl/cmd/storage_create_test.go b/cmd/karavictl/cmd/storage_create_test.go index 0ef95527..7db62b9b 100644 --- a/cmd/karavictl/cmd/storage_create_test.go +++ b/cmd/karavictl/cmd/storage_create_test.go @@ -110,9 +110,9 @@ func TestStorageCreateCmd(t *testing.T) { usts := httptest.NewTLSServer( http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { - case "/univmax/restapi/90/system/version": - fmt.Fprintf(w, `{ "version": "V9.2.1.2"}`) - case "/univmax/restapi/90/system/symmetrix": + case "/univmax/restapi/version": + fmt.Fprintf(w, `{ "version": "V10.0.0.1"}`) + case "/univmax/restapi/100/system/symmetrix": b, err := ioutil.ReadFile(systemInstancesTestDataPath) if err != nil { t.Error(err) @@ -122,7 +122,7 @@ func TestStorageCreateCmd(t *testing.T) { t.Error(err) return } - case "/univmax/restapi/90/system/symmetrix/testing1": + case "/univmax/restapi/100/system/symmetrix/testing1": fmt.Fprintf(w, `{ "symmetrix": [ { "symmetrixId": "000000000001", @@ -132,7 +132,7 @@ func TestStorageCreateCmd(t *testing.T) { "local": true } ], "success": true }"`) - case "/univmax/restapi/90/system/symmetrix/testing2": + case "/univmax/restapi/100/system/symmetrix/testing2": fmt.Fprintf(w, `{ "symmetrix": [ { "symmetrixId": "000000000002", @@ -142,7 +142,7 @@ func TestStorageCreateCmd(t *testing.T) { "local": true } ], "success": true }"`) - case "/univmax/restapi/90/system/symmetrix/testing3": + case "/univmax/restapi/100/system/symmetrix/testing3": fmt.Fprintf(w, `{ "symmetrix": [ { "symmetrixId": "000000000003", @@ -152,7 +152,7 @@ func TestStorageCreateCmd(t *testing.T) { "local": true } ], "success": true }"`) - case "/univmax/restapi/90/system/symmetrix/testing4": + case "/univmax/restapi/100/system/symmetrix/testing4": fmt.Fprintf(w, `{ "symmetrix": [ { "symmetrixId": "000000000003", @@ -162,7 +162,7 @@ func TestStorageCreateCmd(t *testing.T) { "local": true } ], "success": true }"`) - case "/univmax/restapi/90/system/symmetrix/testing5": + case "/univmax/restapi/100/system/symmetrix/testing5": fmt.Fprintf(w, `{ "symmetrix": [ { "symmetrixId": "000000000003", diff --git a/cmd/karavictl/cmd/testdata/unisphere_api_types_System_instances_testing.json b/cmd/karavictl/cmd/testdata/unisphere_api_types_System_instances_testing.json index 9b6de956..9d30795c 100644 --- a/cmd/karavictl/cmd/testdata/unisphere_api_types_System_instances_testing.json +++ b/cmd/karavictl/cmd/testdata/unisphere_api_types_System_instances_testing.json @@ -5,7 +5,5 @@ "testing3", "testing4", "testing5" - ], - "num_of_symmetrix_arrays": 5, - "success": true + ] } diff --git a/internal/proxy/powermax_handler_test.go b/internal/proxy/powermax_handler_test.go index d069755b..c4cb977e 100644 --- a/internal/proxy/powermax_handler_test.go +++ b/internal/proxy/powermax_handler_test.go @@ -101,7 +101,7 @@ func testPowerMaxServeHTTP(t *testing.T) { t.Fatal(err) } r := httptest.NewRequest(http.MethodGet, - "/univmax/restapi/91/sloprovisioning/symmetrix/1234567890/storagegroup/csi-CSM-Bronze-SRP_1-SG/", + "/univmax/restapi/100/sloprovisioning/symmetrix/1234567890/storagegroup/csi-CSM-Bronze-SRP_1-SG/", nil) r.Header.Set("Forwarded", "for=https://1.1.1.1;1234567890") addJWTToRequestHeader(t, r) @@ -122,7 +122,7 @@ func testPowerMaxServeHTTP(t *testing.T) { ) fakeUni := fakeServer(t, http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { t.Logf("fake unisphere received: %s %s", r.Method, r.URL) - if r.URL.Path == "/univmax/restapi/91/sloprovisioning/symmetrix/1234567890/storagegroup/csi-CSM-Bronze-SRP_1-SG" { + if r.URL.Path == "/univmax/restapi/100/sloprovisioning/symmetrix/1234567890/storagegroup/csi-CSM-Bronze-SRP_1-SG" { b, err := ioutil.ReadFile("testdata/powermax_create_volume_response.json") if err != nil { t.Fatal(err) @@ -182,14 +182,14 @@ func testPowerMaxServeHTTP(t *testing.T) { fakeUni := fakeServer(t, http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { t.Logf("fake unisphere received: %s %s", r.Method, r.URL) switch r.URL.Path { - case "/univmax/restapi/91/sloprovisioning/symmetrix/1234567890/volume/003E4": + case "/univmax/restapi/100/sloprovisioning/symmetrix/1234567890/volume/003E4": b, err := ioutil.ReadFile("testdata/powermax_getvolumebyid_response.json") if err != nil { t.Fatal(err) } w.Write(b) return - case "/univmax/restapi/91/sloprovisioning/symmetrix/1234567890/storagegroup/csi-CSM-Bronze-SRP_1-SG": + case "/univmax/restapi/100/sloprovisioning/symmetrix/1234567890/storagegroup/csi-CSM-Bronze-SRP_1-SG": b, err := ioutil.ReadFile("testdata/powermax_getstoragegroup_response.json") if err != nil { t.Fatal(err) diff --git a/internal/role-service/validate/validate_test.go b/internal/role-service/validate/validate_test.go index 56896450..2832e097 100644 --- a/internal/role-service/validate/validate_test.go +++ b/internal/role-service/validate/validate_test.go @@ -232,9 +232,9 @@ func TestValidatePowerMax(t *testing.T) { goodBackendPowerMax := httptest.NewTLSServer( http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { - case "/univmax/restapi/90/system/version": - fmt.Fprintf(w, `{ "version": "V9.2.1.2"}`) - case "/univmax/restapi/90/sloprovisioning/symmetrix/000197900714/srp/bronze": + case "/univmax/restapi/version": + fmt.Fprintf(w, `{ "version": "V10.0.0.1"}`) + case "/univmax/restapi/100/sloprovisioning/symmetrix/000197900714/srp/bronze": w.WriteHeader(http.StatusOK) default: t.Errorf("unhandled unisphere request path: %s", r.URL.Path) @@ -319,9 +319,9 @@ storage: goodBackendPowerMax := httptest.NewTLSServer( http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { - case "/univmax/restapi/90/system/version": - fmt.Fprintf(w, `{ "version": "V9.2.1.2"}`) - case "/univmax/restapi/90/sloprovisioning/symmetrix/000197900714/srp/bronze": + case "/univmax/restapi/version": + fmt.Fprintf(w, `{ "version": "V10.0.0.1"}`) + case "/univmax/restapi/100/sloprovisioning/symmetrix/000197900714/srp/bronze": w.WriteHeader(http.StatusOK) default: t.Errorf("unhandled unisphere request path: %s", r.URL.Path) diff --git a/internal/storage-service/validate/validate_test.go b/internal/storage-service/validate/validate_test.go index c2fd6147..3c3b6d5e 100644 --- a/internal/storage-service/validate/validate_test.go +++ b/internal/storage-service/validate/validate_test.go @@ -193,8 +193,8 @@ func TestValidatePowerMax(t *testing.T) { goodBackendPowerMax := httptest.NewTLSServer( http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { - case "/univmax/restapi/90/system/version": - fmt.Fprintf(w, `{ "version": "V9.2.1.2"}`) + case "/univmax/restapi/version": + fmt.Fprintf(w, `{ "version": "V10.0.0.1"}`) default: t.Errorf("unhandled unisphere request path: %s", r.URL.Path) } From facceefbfcba03cd09f3bba1545732b928dce2ee Mon Sep 17 00:00:00 2001 From: Shayna Finocchiaro <66699024+shaynafinocchiaro@users.noreply.github.com> Date: Thu, 8 Sep 2022 08:01:10 -0400 Subject: [PATCH 3/3] update goclients to latest release --- go.mod | 6 +++--- go.sum | 14 ++++++-------- internal/powerflex/storage_pool_cache.go | 4 ++-- 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/go.mod b/go.mod index 22793840..2e34c64b 100644 --- a/go.mod +++ b/go.mod @@ -4,8 +4,9 @@ go 1.18 require ( github.com/alicebob/miniredis/v2 v2.17.0 - github.com/dell/goisilon v1.8.0 - github.com/dell/goscaleio v1.7.0 + github.com/dell/goisilon v1.9.0 + github.com/dell/gopowermax/v2 v2.0.0 + github.com/dell/goscaleio v1.8.0 github.com/dustin/go-humanize v1.0.0 github.com/fsnotify/fsnotify v1.5.1 github.com/go-redis/redis v6.15.7+incompatible @@ -41,7 +42,6 @@ require ( require ( github.com/beorn7/perks v1.0.1 // indirect github.com/cespare/xxhash/v2 v2.1.2 // indirect - github.com/dell/gopowermax/v2 v2.0.0-20220818034616-a85ab3cf9394 // indirect github.com/evanphx/json-patch v4.12.0+incompatible // indirect github.com/go-logr/stdr v1.2.0 // indirect github.com/golang/protobuf v1.5.2 // indirect diff --git a/go.sum b/go.sum index 9fb78a21..3c33d255 100644 --- a/go.sum +++ b/go.sum @@ -141,14 +141,12 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.0-20210816181553-5444fa50b93d h1:1iy2qD6JEhHKKhUOA9IWs7mjco7lnw2qx8FsRI2wirE= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.0-20210816181553-5444fa50b93d/go.mod h1:tmAIfUFEirG/Y8jhZ9M+h36obRZAk/1fcSpXwAVlfqE= -github.com/dell/goisilon v1.8.0 h1:3CBNKCQMAqyJ8Qz3GiwCHIs2ds1Ur0trSnmR/hBKDX0= -github.com/dell/goisilon v1.8.0/go.mod h1:fJXHyh1JBcbsmPBquEulaNOFTpj1eEN5vISDf/UY1RQ= -github.com/dell/gopowermax v1.8.0 h1:Et02IZjkCTfjUL8vTCmX0pL18hBs54u1ygIuxbpo3zI= -github.com/dell/gopowermax v1.8.0/go.mod h1:rwP7E76NKKl2C+adKe8rDbyfQX4VW041bFbpY0oAKM0= -github.com/dell/gopowermax/v2 v2.0.0-20220818034616-a85ab3cf9394 h1:OJD9eBFRJxTaEx8+tQrCRn4oJssmXTukzzWNsXcXYBw= -github.com/dell/gopowermax/v2 v2.0.0-20220818034616-a85ab3cf9394/go.mod h1:eJEsDN0O0nFqiSdgOXZK73Cv/LlP/+psnkyFSXLR/wI= -github.com/dell/goscaleio v1.7.0 h1:ahc4L2TjrT931WdbuZahUmccuyZMdKbijbTRRvQVBBY= -github.com/dell/goscaleio v1.7.0/go.mod h1:TJbQ8N6hk48w5rEyBa+pRtrRJbPVnCTsYM3mmUyPNaY= +github.com/dell/goisilon v1.9.0 h1:FFZiE71NA+cnfFqm9MYxCg8ADgYzIX969jPrFta6edE= +github.com/dell/goisilon v1.9.0/go.mod h1:fJXHyh1JBcbsmPBquEulaNOFTpj1eEN5vISDf/UY1RQ= +github.com/dell/gopowermax/v2 v2.0.0 h1:k4/p6ml8yHQXw8nECCwY0UriIhpcB/VPoueb80AiMTE= +github.com/dell/gopowermax/v2 v2.0.0/go.mod h1:eJEsDN0O0nFqiSdgOXZK73Cv/LlP/+psnkyFSXLR/wI= +github.com/dell/goscaleio v1.8.0 h1:a5wxvUwqvsr1KGUoHkY5Ol1jsNkQ8VKyTGdFeI5RVLQ= +github.com/dell/goscaleio v1.8.0/go.mod h1:TJbQ8N6hk48w5rEyBa+pRtrRJbPVnCTsYM3mmUyPNaY= github.com/denisenkom/go-mssqldb v0.0.0-20200428022330-06a60b6afbbc/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug= diff --git a/internal/powerflex/storage_pool_cache.go b/internal/powerflex/storage_pool_cache.go index ccd36a93..78ffa2ca 100644 --- a/internal/powerflex/storage_pool_cache.go +++ b/internal/powerflex/storage_pool_cache.go @@ -32,7 +32,7 @@ type StoragePoolCache struct { } // NewStoragePoolCache creates a new StoragePoolCache -// It requires a goscaelio client and a cache size +// It requires a goscaleio client and a cache size func NewStoragePoolCache(client *goscaleio.Client, cacheSize int) (*StoragePoolCache, error) { if client == nil { return nil, fmt.Errorf("goscaleio client is required") @@ -81,7 +81,7 @@ func (c *StoragePoolCache) GetStoragePoolNameByID(ctx context.Context, tokenGett c.client.SetToken(token) - pool, err := c.client.FindStoragePool(id, "", "") + pool, err := c.client.FindStoragePool(id, "", "", "") if err != nil { return "", err }