diff options
Diffstat (limited to 'weed/mount/weedfs_file_read.go')
| -rw-r--r-- | weed/mount/weedfs_file_read.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/weed/mount/weedfs_file_read.go b/weed/mount/weedfs_file_read.go index dc79d3dc7..b1cf2d948 100644 --- a/weed/mount/weedfs_file_read.go +++ b/weed/mount/weedfs_file_read.go @@ -62,6 +62,11 @@ func (wfs *WFS) Read(cancel <-chan struct{}, in *fuse.ReadIn, buff []byte) (fuse glog.Warningf("file handle read %s %d: %v", fh.FullPath(), totalRead, err) return nil, fuse.EIO } + + // Notify ML integration of file read for pattern detection + if wfs.mlIntegration != nil && totalRead > 0 { + wfs.mlIntegration.OnFileRead(in.NodeId, offset, int(totalRead)) + } if IsDebugFileReadWrite { // print(".") |
