Experiment with higher parallelism for drive

This commit is contained in:
Abhishek Pandey 2023-12-19 18:19:25 -08:00
parent 5669619a8d
commit f60aa91e57
2 changed files with 6 additions and 1 deletions

View File

@ -294,12 +294,17 @@ func (w Wrapper) makeSnapshotWithRoot(
Path: root.Name(),
}
parallelism := policy.OptionalInt(10)
trueVal := policy.OptionalBool(true)
errPolicy := &policy.Policy{
ErrorHandlingPolicy: policy.ErrorHandlingPolicy{
IgnoreFileErrors: &trueVal,
IgnoreDirectoryErrors: &trueVal,
},
UploadPolicy: policy.UploadPolicy{
MaxParallelFileReads: &parallelism,
},
}
policyTree, err := policy.TreeForSourceWithOverride(innerCtx, w.c, si, errPolicy)

View File

@ -471,7 +471,7 @@ func (oc *Collection) streamItems(ctx context.Context, errs *fault.Bus) {
int64(len(oc.driveItems)))
defer close(folderProgress)
semaphoreCh := make(chan struct{}, graph.Parallelism(path.OneDriveService).Item())
semaphoreCh := make(chan struct{}, 8)
defer close(semaphoreCh)
ctx = clues.Add(ctx,