From 9bf61accb8be67f7f15f3c4947cb1042faa5ab3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B1=88=E8=BD=A9?= Date: Mon, 14 Apr 2025 15:28:19 +0800 Subject: [PATCH] fix(climc): keystone pprof profile (#22406) --- cmd/climc/shell/misc/pprof.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cmd/climc/shell/misc/pprof.go b/cmd/climc/shell/misc/pprof.go index 26f4c796b7..a319058cb8 100644 --- a/cmd/climc/shell/misc/pprof.go +++ b/cmd/climc/shell/misc/pprof.go @@ -19,6 +19,7 @@ import ( "io" "io/ioutil" "os" + "strings" "syscall" "yunion.io/x/jsonutils" @@ -68,6 +69,10 @@ func init() { return fmt.Errorf("no service address provide") } + if opts.Service == "identity" { + svcUrl = strings.TrimSuffix(svcUrl, "/v3") + } + params := jsonutils.NewDict() params.Add(jsonutils.NewInt(int64(opts.Second)), "seconds") if pType == "heap" && opts.Gc {