Skip to content
Snippets Groups Projects
Commit ffd5ad91 authored by Sung-Kyu Yoo's avatar Sung-Kyu Yoo Committed by Derek Su
Browse files

Added an option for provisioner worker threads.

parent 4f01290f
No related branches found
No related tags found
No related merge requests found
......@@ -39,6 +39,8 @@ var (
FlagConfigMapName = "configmap-name"
FlagHelperPodFile = "helper-pod-file"
DefaultHelperPodFile = "helperPod.yaml"
FlagWorkerThreads = "worker-threads"
DefaultWorkerThreads = 4
)
func cmdNotFound(c *cli.Context, command string) {
......@@ -107,6 +109,11 @@ func StartCmd() cli.Command {
Usage: "Paths to the Helper pod yaml file",
Value: "",
},
cli.IntFlag{
Name: FlagWorkerThreads,
Usage: "Number of provisioner worker threads.",
Value: DefaultWorkerThreads,
},
},
Action: func(c *cli.Context) {
if err := startDaemon(c); err != nil {
......@@ -232,6 +239,7 @@ func startDaemon(c *cli.Context) error {
provisioner,
serverVersion.GitVersion,
pvController.LeaderElection(false),
pvController.Threadiness(c.Int(FlagWorkerThreads)),
)
logrus.Debug("Provisioner started")
pc.Run(stopCh)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment