Skip to content

Commit

Permalink
Add context propagation to rclone
Browse files Browse the repository at this point in the history
- Change rclone/fs interfaces to accept context.Context
- Update interface implementations to use context.Context
- Change top level usage to propagate context to lover level functions

Context propagation is needed for stopping transfers and passing other
request-scoped values.
  • Loading branch information
ajankovic authored and ncw committed Jun 19, 2019
1 parent a2c317b commit f78cd1e
Show file tree
Hide file tree
Showing 156 changed files with 2,570 additions and 2,380 deletions.
3 changes: 2 additions & 1 deletion backend/alias/alias_internal_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package alias

import (
"context"
"fmt"
"path"
"path/filepath"
Expand Down Expand Up @@ -69,7 +70,7 @@ func TestNewFS(t *testing.T) {
prepare(t, remoteRoot)
f, err := fs.NewFs(fmt.Sprintf("%s:%s", remoteName, test.fsRoot))
require.NoError(t, err, what)
gotEntries, err := f.List(test.fsList)
gotEntries, err := f.List(context.Background(), test.fsList)
require.NoError(t, err, what)

sort.Sort(gotEntries)
Expand Down
Loading

0 comments on commit f78cd1e

Please sign in to comment.