Merge pull request #84137 from cwdsuzhou/Octo/add_success_events

Add an event to pvc when node expand successfully
This commit is contained in:
Kubernetes Prow Robot 2019-10-24 07:33:15 -07:00 committed by GitHub
commit 900c0cf0b6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1757,6 +1757,7 @@ func (og *operationGenerator) nodeExpandVolume(volumeToMount VolumeToMount, rsOp
}
simpleMsg, detailedMsg := volumeToMount.GenerateMsg("MountVolume.NodeExpandVolume succeeded", "")
og.recorder.Eventf(volumeToMount.Pod, v1.EventTypeNormal, kevents.FileSystemResizeSuccess, simpleMsg)
og.recorder.Eventf(pvc, v1.EventTypeNormal, kevents.FileSystemResizeSuccess, simpleMsg)
klog.Infof(detailedMsg)
// File system resize succeeded, now update the PVC's Capacity to match the PV's
err = util.MarkFSResizeFinished(pvc, pvSpecCap, og.kubeClient)