add toggle for using the delta tree via cli (#4694)
#### Does this PR need a docs update or release note? - [x] ⛔ No #### Issue(s) * #4690 #### Test Plan - [x] ⚡ Unit test
This commit is contained in:
parent
8cf2c1b294
commit
d45842fe5c
@ -67,6 +67,12 @@ func addOneDriveCommands(cmd *cobra.Command) *cobra.Command {
|
||||
|
||||
flags.AddUserFlag(c)
|
||||
flags.AddGenericBackupFlags(c)
|
||||
fs.BoolVar(
|
||||
&flags.UseDeltaTreeFV,
|
||||
flags.UseDeltaTreeFN,
|
||||
false,
|
||||
"process backups using the delta tree instead of standard enumeration")
|
||||
cobra.CheckErr(fs.MarkHidden(flags.UseDeltaTreeFN))
|
||||
|
||||
case listCommand:
|
||||
c, fs = utils.AddCommand(cmd, oneDriveListCmd())
|
||||
|
||||
@ -12,6 +12,8 @@ const (
|
||||
FileCreatedBeforeFN = "file-created-before"
|
||||
FileModifiedAfterFN = "file-modified-after"
|
||||
FileModifiedBeforeFN = "file-modified-before"
|
||||
|
||||
UseDeltaTreeFN = "use-delta-tree"
|
||||
)
|
||||
|
||||
var (
|
||||
@ -22,6 +24,8 @@ var (
|
||||
FileCreatedBeforeFV string
|
||||
FileModifiedAfterFV string
|
||||
FileModifiedBeforeFV string
|
||||
|
||||
UseDeltaTreeFV bool
|
||||
)
|
||||
|
||||
// AddOneDriveDetailsAndRestoreFlags adds flags that are common to both the
|
||||
|
||||
@ -27,6 +27,7 @@ func Control() control.Options {
|
||||
opt.ToggleFeatures.DisableDelta = flags.DisableDeltaFV
|
||||
opt.ToggleFeatures.DisableSlidingWindowLimiter = flags.DisableSlidingWindowLimiterFV
|
||||
opt.ToggleFeatures.ExchangeImmutableIDs = flags.EnableImmutableIDFV
|
||||
opt.ToggleFeatures.UseDeltaTree = flags.UseDeltaTreeFV
|
||||
opt.Parallelism.ItemFetch = flags.FetchParallelismFV
|
||||
|
||||
return opt
|
||||
|
||||
@ -109,4 +109,7 @@ type Toggles struct {
|
||||
// Setting this flag switches exchange backups to fallback to the default token
|
||||
// bucket rate limiter.
|
||||
DisableSlidingWindowLimiter bool `json:"disableSlidingWindowLimiter"`
|
||||
|
||||
// see: https://github.com/alcionai/corso/issues/4688
|
||||
UseDeltaTree bool `json:"useDeltaTree"`
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user