@@ -864,14 +864,13 @@ func (d *Driver) CreateSnapshot(ctx context.Context, req *csi.CreateSnapshotRequ
864
864
return nil , status .Error (codes .InvalidArgument , "CreateSnapshot Source Volume ID must be provided" )
865
865
}
866
866
867
- rgName , accountName , fileShareName , _ , _ , srcVolSubsID , err := GetFileShareInfo (sourceVolumeID ) //nolint:dogsled
867
+ rgName , accountName , fileShareName , _ , _ , subsID , err := GetFileShareInfo (sourceVolumeID ) //nolint:dogsled
868
868
if err != nil {
869
869
return nil , status .Error (codes .Internal , fmt .Sprintf ("GetFileShareInfo(%s) failed with error: %v" , sourceVolumeID , err ))
870
870
}
871
871
if rgName == "" {
872
872
rgName = d .cloud .ResourceGroup
873
873
}
874
- subsID := srcVolSubsID
875
874
if subsID == "" {
876
875
subsID = d .cloud .SubscriptionID
877
876
}
@@ -908,7 +907,7 @@ func (d *Driver) CreateSnapshot(ctx context.Context, req *csi.CreateSnapshotRequ
908
907
return & csi.CreateSnapshotResponse {
909
908
Snapshot : & csi.Snapshot {
910
909
SizeBytes : volumehelper .GiBToBytes (int64 (itemSnapshotQuota )),
911
- SnapshotId : getSnapshotID ( srcVolSubsID , sourceVolumeID , itemSnapshot , subsID ) ,
910
+ SnapshotId : sourceVolumeID + "#" + itemSnapshot ,
912
911
SourceVolumeId : sourceVolumeID ,
913
912
CreationTime : timestamppb .New (itemSnapshotTime ),
914
913
// Since the snapshot of azurefile has no field of ReadyToUse, here ReadyToUse is always set to true.
@@ -979,7 +978,7 @@ func (d *Driver) CreateSnapshot(ctx context.Context, req *csi.CreateSnapshotRequ
979
978
createResp := & csi.CreateSnapshotResponse {
980
979
Snapshot : & csi.Snapshot {
981
980
SizeBytes : volumehelper .GiBToBytes (int64 (itemSnapshotQuota )),
982
- SnapshotId : getSnapshotID ( srcVolSubsID , sourceVolumeID , itemSnapshot , subsID ) ,
981
+ SnapshotId : sourceVolumeID + "#" + itemSnapshot ,
983
982
SourceVolumeId : sourceVolumeID ,
984
983
CreationTime : timestamppb .New (itemSnapshotTime ),
985
984
// Since the snapshot of azurefile has no field of ReadyToUse, here ReadyToUse is always set to true.
0 commit comments