You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ncw edit: When transferring big files from the local backend, they often take an extremely long time to generate the hash. It would be nice if this was visible to the user somehow.
// ServerSideCopyStart should be called at the start of a server-side copy
//
// This pretends a transfer has started
func (acc*Account) ServerSideCopyStart() {
acc.values.mu.Lock()
// Set start time.
ifacc.values.start.IsZero() {
acc.values.start=time.Now()
}
acc.values.mu.Unlock()
}
// ServerSideCopyEnd accounts for a read of n bytes in a sever side copy
func (acc*Account) ServerSideCopyEnd(nint64) {
// Update Stats
acc.values.mu.Lock()
acc.values.bytes+=n
acc.values.mu.Unlock()
acc.stats.Bytes(n)
}
If checksums for the local backend always used this mechanism then it would solve the UI problem were users are wondering why their B2/S3 uploads don't start because the local backend is making the checksum in advance...
I still don't like current pacer. In case of many files it walks up next --checkers files, calculates ETA, then adds next checker, updates ETA and so on. This way ETA is pretty small all the time seeing only partial work, then steadily decreases close to zero, then jumps back to another small duration, then again. This is useless in practice.
To achieve this we'd want to move some of the logic from fs/sync into fs/march or possibly run rclone check from the rclone sync framework rather than using fs/march.
The logic missing is queuing the checks so we have an idea of how many we need to do which is only in fs/sync.
Anyway I think any of these suggestions should probably go in a new PR
Activity
ivandeex commentedon Dec 4, 2020
Implementation of this request is somewhat related to #2740 as it activates pacer/accounting inside the call stack hash>download>localfs.
ivandeex commentedon May 29, 2021
Let me copy here a comment by @ncw from #5352 (comment)