-
Notifications
You must be signed in to change notification settings - Fork 371
Description
The CSI external-provisioner relies on the external-provisioner library https://github.com/kubernetes-incubator/external-storage/blob/master/lib/controller/controller.go
In that library the provisioning code will attempt to provision a volume, if provisioning fails it will try to delete the volume to cleanup (see https://github.com/kubernetes-incubator/external-storage/blob/master/lib/controller/controller.go#L935).
If the failure was due to the volume provisioning taking too long, this just makes the problem: Volume provisioning is triggered, it takes too long so the call times out, the volume is deleted, we still want the volume so provisioning is triggered again but timesout before it is complete, and then is deleted, so every retry it will have to start over.
Instead if we fail due to error, we should not delete the volume. We should only delete once the request for provisioning is gone (i.e. PVC is deleted).
CC @sbezverk thoughts?
Reported by @cduchesne