Skip to content

Commit

Permalink
updage gopowerstore mod to add fractured state enum
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeatdell committed Oct 1, 2024
1 parent 0da029e commit 7590e1b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ require (
github.com/dell/gofsutil v1.16.1
github.com/dell/goiscsi v1.9.0
github.com/dell/gonvme v1.8.1
github.com/dell/gopowerstore v1.15.2-0.20240925141718-82897478ca7f
github.com/dell/gopowerstore v1.15.2-0.20241001202140-db2de61a4338
github.com/fsnotify/fsnotify v1.7.0
github.com/go-openapi/strfmt v0.23.0
github.com/golang/mock v1.6.0
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,8 @@ github.com/dell/gopowerstore v1.15.2-0.20240924212949-8aecb0c6e9d9 h1:H2aTOEFVZy
github.com/dell/gopowerstore v1.15.2-0.20240924212949-8aecb0c6e9d9/go.mod h1:vyN1JAZ+TO7Px+gNVa61a23/KwlI/Nj/6ttzMOQFyG0=
github.com/dell/gopowerstore v1.15.2-0.20240925141718-82897478ca7f h1:YdBsmUfMIFRQfOvgBCtfQAXYCmhR+4elNFHDiOs8k7Y=
github.com/dell/gopowerstore v1.15.2-0.20240925141718-82897478ca7f/go.mod h1:vyN1JAZ+TO7Px+gNVa61a23/KwlI/Nj/6ttzMOQFyG0=
github.com/dell/gopowerstore v1.15.2-0.20241001202140-db2de61a4338 h1:YwWUcphY/HY5rPYY2g9vJnLMbOAgD/ITEdz6nlVW9nI=
github.com/dell/gopowerstore v1.15.2-0.20241001202140-db2de61a4338/go.mod h1:vyN1JAZ+TO7Px+gNVa61a23/KwlI/Nj/6ttzMOQFyG0=
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE=
Expand Down
4 changes: 2 additions & 2 deletions pkg/controller/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ func (s *Service) CreateVolume(ctx context.Context, req *csi.CreateVolumeRequest
metroVGSession.State != gopowerstore.RsStateSynchronizing &&
metroVGSession.State != gopowerstore.RsStatePaused &&
metroVGSession.State != gopowerstore.RsStateSystemPaused &&
metroVGSession.State != "Fractured" {
metroVGSession.State != gopowerstore.RsStateFractured {
return nil, status.Errorf(codes.FailedPrecondition,
"cannot add volumes to volume group %s because the metro replication session is not in expected state to pause: %s", vg.Name, err.Error())
}
Expand Down Expand Up @@ -846,7 +846,7 @@ func (s *Service) DeleteVolume(ctx context.Context, req *csi.DeleteVolumeRequest
metroSession.State != gopowerstore.RsStateSynchronizing &&
metroSession.State != gopowerstore.RsStatePaused &&
metroSession.State != gopowerstore.RsStateSystemPaused &&
metroSession.State != "Fractured" {
metroSession.State != gopowerstore.RsStateFractured {
return nil, status.Errorf(codes.FailedPrecondition,
"failed to delete volume %s because the metro replication session is in %s state", id, metroSession.State)
}
Expand Down

0 comments on commit 7590e1b

Please sign in to comment.