Skip to content

Commit

Permalink
Merge pull request #337 from red-hat-storage/sync_us--devel
Browse files Browse the repository at this point in the history
Syncing latest changes from upstream devel for ceph-csi
  • Loading branch information
openshift-merge-bot[bot] authored Jul 11, 2024
2 parents c141b7a + d376271 commit 5ddb243
Show file tree
Hide file tree
Showing 9 changed files with 8,464 additions and 4,521 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ require (
github.com/aws/aws-sdk-go-v2/service/sts v1.30.1
github.com/ceph/ceph-csi/api v0.0.0-00010101000000-000000000000
github.com/ceph/go-ceph v0.28.0
github.com/container-storage-interface/spec v1.9.0
github.com/container-storage-interface/spec v1.10.0
github.com/csi-addons/spec v0.2.1-0.20240619103729-12c61f25a2a5
github.com/gemalto/kmip-go v0.0.10
github.com/golang/protobuf v1.5.4
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -893,8 +893,8 @@ github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4/go.mod h1:eXthEFrGJvWH
github.com/cncf/xds/go v0.0.0-20240423153145-555b57ec207b h1:ga8SEFjZ60pxLcmhnThWgvH2wg8376yUJmPhEH4H3kw=
github.com/cncf/xds/go v0.0.0-20240423153145-555b57ec207b/go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8=
github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU=
github.com/container-storage-interface/spec v1.9.0 h1:zKtX4STsq31Knz3gciCYCi1SXtO2HJDecIjDVboYavY=
github.com/container-storage-interface/spec v1.9.0/go.mod h1:ZfDu+3ZRyeVqxZM0Ds19MVLkN2d1XJ5MAfi1L3VjlT0=
github.com/container-storage-interface/spec v1.10.0 h1:YkzWPV39x+ZMTa6Ax2czJLLwpryrQ+dPesB34mrRMXA=
github.com/container-storage-interface/spec v1.10.0/go.mod h1:DtUvaQszPml1YJfIK7c00mlv6/g4wNMLanLgiUbKFRI=
github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
Expand Down
14 changes: 7 additions & 7 deletions internal/cephfs/groupcontrollerserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ func (cs *ControllerServer) CreateVolumeGroupSnapshot(
CreationTime: timestamppb.New(time.Now()),
}

for _, r := range *resp {
for _, r := range resp {
r.Snapshot.GroupSnapshotId = vgs.VolumeGroupSnapshotID
response.GroupSnapshot.Snapshots = append(response.GroupSnapshot.Snapshots, r.GetSnapshot())
}
Expand Down Expand Up @@ -260,7 +260,7 @@ func (cs *ControllerServer) releaseQuiesceAndGetVolumeGroupSnapshotResponse(
}
}
}()
snapshotResponses := make([]csi.CreateSnapshotResponse, 0)
snapshotResponses := make([]*csi.CreateSnapshotResponse, 0)
for _, volID := range req.GetSourceVolumeIds() {
// Create the snapshot for the volumeID
clusterID := getClusterIDForVolumeID(fsMap, volID)
Expand All @@ -281,7 +281,7 @@ func (cs *ControllerServer) releaseQuiesceAndGetVolumeGroupSnapshotResponse(
"failed to create snapshot and add to volume group journal: %v",
err)
}
snapshotResponses = append(snapshotResponses, *resp)
snapshotResponses = append(snapshotResponses, resp)
}

response := &csi.CreateVolumeGroupSnapshotResponse{}
Expand Down Expand Up @@ -314,13 +314,13 @@ func (cs *ControllerServer) createSnapshotAddToVolumeGroupJournal(
vgs *store.VolumeGroupSnapshotIdentifier,
cr *util.Credentials,
fsMap map[string]core.FSQuiesceClient) (
*[]csi.CreateSnapshotResponse,
[]*csi.CreateSnapshotResponse,
error,
) {
var err error
var resp *csi.CreateSnapshotResponse

responses := make([]csi.CreateSnapshotResponse, 0)
responses := make([]*csi.CreateSnapshotResponse, 0)
for _, volID := range req.GetSourceVolumeIds() {
err = fsQuiesceWithExpireTimeout(ctx, vgo.RequestName, fsMap)
if err != nil {
Expand All @@ -345,7 +345,7 @@ func (cs *ControllerServer) createSnapshotAddToVolumeGroupJournal(

return nil, err
}
responses = append(responses, *resp)
responses = append(responses, resp)
}

err = releaseFSQuiesce(ctx, vgo.RequestName, fsMap)
Expand All @@ -355,7 +355,7 @@ func (cs *ControllerServer) createSnapshotAddToVolumeGroupJournal(
return nil, err
}

return &responses, nil
return responses, nil
}

func formatCreateSnapshotRequest(volID, groupSnapshotName,
Expand Down
2 changes: 1 addition & 1 deletion internal/csi-common/identityserver-default.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (

// DefaultIdentityServer stores driver object.
type DefaultIdentityServer struct {
csi.UnimplementedControllerServer
csi.UnimplementedIdentityServer
Driver *CSIDriver
}

Expand Down
2 changes: 1 addition & 1 deletion internal/util/topology.go
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ func FindPoolAndTopology(topologyPools *[]TopologyConstrainedPool,

return "", "", nil, fmt.Errorf("none of the topology constrained pools matched requested "+
"topology constraints : pools (%+v) requested topology (%+v)",
*topologyPools, *accessibilityRequirements)
*topologyPools, accessibilityRequirements)
}

// matchPoolToTopology loops through passed in pools, and for each pool checks if all
Expand Down
Loading

0 comments on commit 5ddb243

Please sign in to comment.