E2E support sets the --item-block-worker-count. (#8836)

Signed-off-by: Xun Jiang <xun.jiang@broadcom.com>
Signed-off-by: hu-keyu <hzldd999@gmail.com>
pull/8864/head
Xun Jiang/Bruce Jiang 2025-04-09 08:30:51 +08:00 committed by hu-keyu
parent 16023c10c3
commit 5a5b80c39e
4 changed files with 15 additions and 1 deletions

View File

@ -116,6 +116,8 @@ FEATURES ?=
DEBUG_VELERO_POD_RESTART ?= false
VELERO_SERVER_DEBUG_MODE ?= false
ITEM_BLOCK_WORKER_COUNT ?= 1
# Parameters to run migration tests along with all other E2E tests, and both of them should
# be provided or left them all empty to skip migration tests with no influence to other
# E2E tests.
@ -167,7 +169,8 @@ COMMON_ARGS := --velerocli=$(VELERO_CLI) \
--uploader-type=$(UPLOADER_TYPE) \
--debug-velero-pod-restart=$(DEBUG_VELERO_POD_RESTART) \
--fail-fast=$(FAIL_FAST) \
--has-vsphere-plugin=$(HAS_VSPHERE_PLUGIN)
--has-vsphere-plugin=$(HAS_VSPHERE_PLUGIN) \
--item-block-worker-count=$(ITEM_BLOCK_WORKER_COUNT)
# Make sure ginkgo is in $GOBIN
.PHONY:ginkgo

View File

@ -343,6 +343,12 @@ func init() {
false,
"a switch for installing vSphere plugin.",
)
flag.IntVar(
&test.VeleroCfg.ItemBlockWorkerCount,
"item-block-worker-count",
1,
"Velero backup's item block worker count.",
)
}
// Add label [SkipVanillaZfs]:

View File

@ -367,6 +367,10 @@ func installVeleroServer(ctx context.Context, cli, cloudProvider string, options
args = append(args, fmt.Sprintf("--uploader-type=%v", options.UploaderType))
}
if options.ItemBlockWorkerCount > 1 {
args = append(args, fmt.Sprintf("--item-block-worker-count=%d", options.ItemBlockWorkerCount))
}
if err := createVeleroResources(ctx, cli, namespace, args, options); err != nil {
return err
}

View File

@ -280,6 +280,7 @@ func getProviderVeleroInstallOptions(veleroCfg *VeleroConfig,
io.VeleroPodMemLimit = veleroCfg.VeleroPodMemLimit
io.VeleroPodMemRequest = veleroCfg.VeleroPodMemRequest
io.DisableInformerCache = veleroCfg.DisableInformerCache
io.ItemBlockWorkerCount = veleroCfg.ItemBlockWorkerCount
return io, nil
}