Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ws-daemon] Filter tasks log if the file does not exists #4952

Merged
merged 1 commit into from
Jul 26, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion components/ws-daemon/pkg/resources/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ package resources
import (
"container/ring"
"context"
"errors"
"fmt"
"io/fs"
"os"
"path/filepath"
"strconv"
Expand Down Expand Up @@ -282,7 +284,9 @@ func (gov *Controller) controlProcessPriorities() {
fn := filepath.Join(gov.CGroupBasePath, "pids", gov.CGroupPath, "tasks")
fc, err := os.ReadFile(fn)
if err != nil {
gov.log.WithError(err).Warn("cannot read tasks file")
if !errors.Is(err, fs.ErrNotExist) {
gov.log.WithError(err).Warn("cannot read tasks file")
}
return
}

Expand Down