mirror of
https://github.com/kubevela/kubevela.git
synced 2026-02-14 18:10:21 +00:00
Fix: pprof addr checked before parsed (#5495)
Signed-off-by: Somefive <yd219913@alibaba-inc.com>
This commit is contained in:
@@ -86,9 +86,6 @@ the core control loops shipped with KubeVela`,
|
||||
for _, set := range namedFlagSets.FlagSets {
|
||||
fs.AddFlagSet(set)
|
||||
}
|
||||
if s.PprofAddr != "" {
|
||||
go pkgutil.EnablePprof(s.PprofAddr, nil)
|
||||
}
|
||||
meta.Name = types.VelaCoreName
|
||||
|
||||
klog.InfoS("KubeVela information", "version", version.VelaVersion, "revision", version.GitRevision)
|
||||
@@ -114,6 +111,10 @@ func run(ctx context.Context, s *options.CoreOptions) error {
|
||||
"Burst", restConfig.Burst,
|
||||
)
|
||||
|
||||
if s.PprofAddr != "" {
|
||||
go pkgutil.EnablePprof(s.PprofAddr, nil)
|
||||
}
|
||||
|
||||
// wrapper the round tripper by multi cluster rewriter
|
||||
if s.EnableClusterGateway {
|
||||
client, err := multicluster.Initialize(restConfig, true)
|
||||
|
||||
Reference in New Issue
Block a user