mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-21 02:41:25 +00:00
Merge pull request #60187 from humblec/error-util
Automatic merge from submit-queue (batch tested with PRs 60427, 60361, 60364, 58625, 60187). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Avoid explicit mention of glusterfs in error strings. Signed-off-by: Humble Chirammal <hchiramm@redhat.com> **What this PR does / why we need it**: **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*: Fixes # **Special notes for your reviewer**: **Release note**: ```release-note ```
This commit is contained in:
commit
9c57bf74b3
@ -34,17 +34,17 @@ func readGlusterLog(path string, podName string) error {
|
||||
var line2 string
|
||||
linecount := 0
|
||||
|
||||
glog.Infof("glusterfs: failure, now attempting to read the gluster log for pod %s", podName)
|
||||
glog.Infof("failure, now attempting to read the gluster log for pod %s", podName)
|
||||
|
||||
// Check and make sure path exists
|
||||
if len(path) == 0 {
|
||||
return fmt.Errorf("glusterfs: log file does not exist for pod: %s", podName)
|
||||
return fmt.Errorf("log file does not exist for pod %s", podName)
|
||||
}
|
||||
|
||||
// open the log file
|
||||
file, err := os.Open(path)
|
||||
if err != nil {
|
||||
return fmt.Errorf("glusterfs: could not open log file for pod: %s", podName)
|
||||
return fmt.Errorf("could not open log file for pod %s", podName)
|
||||
}
|
||||
defer file.Close()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user