Skip to content

Commit 99693ea

Browse files
authored
Remove ZAPI block above ONTAP 9.17
1 parent 2c477c3 commit 99693ea

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

storage_drivers/ontap/api/ontap_zapi.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ var featuresByVersion = map[Feature]*versionutils.Version{
221221
NVMeProtocol: versionutils.MustParseSemantic("9.10.1"),
222222
}
223223

224-
var MaximumONTAPIVersion = versionutils.MustParseMajorMinorVersion("9.17")
224+
var MaximumONTAPIVersion = versionutils.MustParseMajorMinorVersion("9.99")
225225

226226
// SupportsFeature returns true if the Ontapi version supports the supplied feature
227227
func (c Client) SupportsFeature(ctx context.Context, feature Feature) bool {

storage_drivers/ontap/api/ontap_zapi_test.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -51,19 +51,19 @@ func TestIsZAPISupported(t *testing.T) {
5151
},
5252
{
5353
name: "Unsupported version",
54-
version: "9.18.1",
54+
version: "9.100.1",
5555
isSupported: false,
56-
isSupportedErrMsg: "negative test, version 9.18.1 is not supported, expected false but got true",
56+
isSupportedErrMsg: "negative test, version 9.100.1 is not supported, expected false but got true",
5757
wantErr: false,
58-
wantErrMsg: "9.18.1 is a correct semantics, error was not expected",
58+
wantErrMsg: "9.100.1 is a correct semantics, error was not expected",
5959
},
6060
{
61-
name: "Patch version i.e. 9.17.x",
62-
version: "9.17.2",
61+
name: "Patch version i.e. 9.99.x",
62+
version: "9.99.2",
6363
isSupported: true,
64-
isSupportedErrMsg: "positive test, version 9.17.2, expected true but got false",
64+
isSupportedErrMsg: "positive test, version 9.99.2, expected true but got false",
6565
wantErr: false,
66-
wantErrMsg: "9.17.2 is a correct semantics, error was not expected",
66+
wantErrMsg: "9.99.2 is a correct semantics, error was not expected",
6767
},
6868
{
6969
name: "Invalid version",

storage_drivers/ontap/ontap_common.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1392,7 +1392,7 @@ func InitializeOntapAPI(
13921392
return nil, err
13931393
}
13941394

1395-
// Is the ONTAP version lesser than or equal to "9.17.x"?
1395+
// Is the ONTAP version lesser than or equal to "9.99.x"?
13961396
IsZAPISupported, err := api.IsZAPISupported(ontapVer)
13971397
if err != nil {
13981398
return nil, err
@@ -1410,12 +1410,12 @@ func InitializeOntapAPI(
14101410
A. Existing or new users, who haven't set the useREST flag or set it to false, will use the ZAPI client by default,
14111411
overriding the `ontapAPI` var, thereby discarding the previously created REST client above.
14121412
B. If the user has set the useREST flag to true, the REST client created earlier is used.
1413-
3. If the ONTAP version lies between "9.15.1" and "9.17.x":
1413+
3. If the ONTAP version lies between "9.15.1" and "9.99.x":
14141414
A. Both REST and ZAPI are supported. If the user has not set the useREST flag or set it to true,
14151415
the REST client created earlier is used.
14161416
B. If the user has set the useREST flag to false, a ZAPI client is created,
14171417
overriding the `ontapAPI` var, thereby discarding the previously created REST client above.
1418-
4. If the ONTAP version is greater than "9.17.x":
1418+
4. If the ONTAP version is greater than "9.99.x":
14191419
A. ZAPI calls are not supported by ONTAP. In this case, if the user has set the useREST flag to false,
14201420
an error is returned.
14211421
B. Otherwise, the REST client created earlier is used by default.

0 commit comments

Comments
 (0)