Commit 823d760a authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #39844 from screeley44/replica_bug

Automatic merge from submit-queue (batch tested with PRs 39807, 37505, 39844, 39525, 39109) fix bug not using volumetype config in create volume fixes #39843 @humblec we are building the volumetype config but I don't see where we are using it in the CreateVolume for dyn provisioning, this is why volumetype parameter from the Storage Class was being overlooked because we are hard coding constants like replicaCount which is always 3. unless I'm missing something?
parents 6b5d82b5 164809c8
...@@ -710,7 +710,7 @@ func (p *glusterfsVolumeProvisioner) CreateVolume(gid int) (r *v1.GlusterfsVolum ...@@ -710,7 +710,7 @@ func (p *glusterfsVolumeProvisioner) CreateVolume(gid int) (r *v1.GlusterfsVolum
glog.V(4).Infof("glusterfs: provided clusterids: %v", clusterIds) glog.V(4).Infof("glusterfs: provided clusterids: %v", clusterIds)
} }
gid64 := int64(gid) gid64 := int64(gid)
volumeReq := &gapi.VolumeCreateRequest{Size: sz, Clusters: clusterIds, Gid: gid64, Durability: gapi.VolumeDurabilityInfo{Type: durabilityType, Replicate: gapi.ReplicaDurability{Replica: replicaCount}}} volumeReq := &gapi.VolumeCreateRequest{Size: sz, Clusters: clusterIds, Gid: gid64, Durability: p.volumeType}
volume, err := cli.VolumeCreate(volumeReq) volume, err := cli.VolumeCreate(volumeReq)
if err != nil { if err != nil {
glog.Errorf("glusterfs: error creating volume %v ", err) glog.Errorf("glusterfs: error creating volume %v ", err)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment