mirror of
https://github.com/cubefs/cubefs.git
synced 2026-08-02 02:00:56 +00:00
refactor(client): not report eio for extent not found error. #1000123658
Signed-off-by: Victor1319 <zengxuewei@oppo.com>
This commit is contained in:
parent
71002fbcf0
commit
a20e91c651
@ -400,7 +400,7 @@ func (f *File) Read(ctx context.Context, req *fuse.ReadRequest, resp *fuse.ReadR
|
||||
msg := fmt.Sprintf("Read: ino(%v) req(%v) err(%v) size(%v)", f.info.Inode, req, err, size)
|
||||
f.super.handleError("Read", msg)
|
||||
errMetric := exporter.NewCounter("fileReadFailed")
|
||||
if err == syscall.EOPNOTSUPP || err == syscall.ENOTSUP {
|
||||
if err == syscall.EOPNOTSUPP || err == syscall.ENOTSUP || strings.Contains(err.Error(), "ExtentNotFoundError") {
|
||||
errMetric.AddWithLabels(1, map[string]string{exporter.Vol: f.super.volname, exporter.Err: "NOTSUP"})
|
||||
} else {
|
||||
errMetric.AddWithLabels(1, map[string]string{exporter.Vol: f.super.volname, exporter.Err: "EIO"})
|
||||
|
||||
Loading…
Reference in New Issue
Block a user