From 17a3f3df663fdd18f4615fc58e56630055b45083 Mon Sep 17 00:00:00 2001 From: Weizhen Wang Date: Wed, 5 Jul 2023 17:27:44 +0800 Subject: [PATCH 1/3] This is an automated cherry-pick of #45177 Signed-off-by: ti-chi-bot --- executor/analyze.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/executor/analyze.go b/executor/analyze.go index b0f55eb592561..97a70c497f827 100644 --- a/executor/analyze.go +++ b/executor/analyze.go @@ -19,8 +19,12 @@ import ( "context" "fmt" "math" +<<<<<<< HEAD "math/rand" "sort" +======= + "net" +>>>>>>> db381848680 (statistic: improve ipv6 for analyze job meta (#45177)) "strconv" "strings" "sync" @@ -2489,7 +2493,7 @@ func AddNewAnalyzeJob(ctx sessionctx.Context, job *statistics.AnalyzeJob) { logutil.BgLogger().Error("failed to get server info", zap.Error(err)) instance = "unknown" } else { - instance = fmt.Sprintf("%s:%d", serverInfo.IP, serverInfo.Port) + instance = net.JoinHostPort(serverInfo.IP, strconv.Itoa(int(serverInfo.Port))) } statsHandle := domain.GetDomain(ctx).StatsHandle() err = statsHandle.InsertAnalyzeJob(job, instance, ctx.GetSessionVars().ConnectionID) From b24d7078cd36d4b84a70ffe74fc60eab3529fb7b Mon Sep 17 00:00:00 2001 From: Weizhen Wang Date: Wed, 5 Jul 2023 17:41:46 +0800 Subject: [PATCH 2/3] update Signed-off-by: Weizhen Wang --- bazel-bin | 1 + bazel-out | 1 + bazel-testlogs | 1 + bazel-tidb | 1 + executor/analyze.go | 5 +---- 5 files changed, 5 insertions(+), 4 deletions(-) create mode 120000 bazel-bin create mode 120000 bazel-out create mode 120000 bazel-testlogs create mode 120000 bazel-tidb diff --git a/bazel-bin b/bazel-bin new file mode 120000 index 0000000000000..cb9d2f5048470 --- /dev/null +++ b/bazel-bin @@ -0,0 +1 @@ +/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__/bazel-out/darwin_arm64-fastbuild/bin \ No newline at end of file diff --git a/bazel-out b/bazel-out new file mode 120000 index 0000000000000..dab0101f8988f --- /dev/null +++ b/bazel-out @@ -0,0 +1 @@ +/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__/bazel-out \ No newline at end of file diff --git a/bazel-testlogs b/bazel-testlogs new file mode 120000 index 0000000000000..377400ba0073b --- /dev/null +++ b/bazel-testlogs @@ -0,0 +1 @@ +/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__/bazel-out/darwin_arm64-fastbuild/testlogs \ No newline at end of file diff --git a/bazel-tidb b/bazel-tidb new file mode 120000 index 0000000000000..40be33516b288 --- /dev/null +++ b/bazel-tidb @@ -0,0 +1 @@ +/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__ \ No newline at end of file diff --git a/executor/analyze.go b/executor/analyze.go index 97a70c497f827..97ab335b49eb9 100644 --- a/executor/analyze.go +++ b/executor/analyze.go @@ -19,12 +19,9 @@ import ( "context" "fmt" "math" -<<<<<<< HEAD "math/rand" - "sort" -======= "net" ->>>>>>> db381848680 (statistic: improve ipv6 for analyze job meta (#45177)) + "sort" "strconv" "strings" "sync" From 3560e1e7673e4ce7b3ec764affee4b3ce58fc379 Mon Sep 17 00:00:00 2001 From: Weizhen Wang Date: Wed, 5 Jul 2023 17:41:59 +0800 Subject: [PATCH 3/3] update Signed-off-by: Weizhen Wang --- bazel-bin | 1 - bazel-out | 1 - bazel-testlogs | 1 - bazel-tidb | 1 - 4 files changed, 4 deletions(-) delete mode 120000 bazel-bin delete mode 120000 bazel-out delete mode 120000 bazel-testlogs delete mode 120000 bazel-tidb diff --git a/bazel-bin b/bazel-bin deleted file mode 120000 index cb9d2f5048470..0000000000000 --- a/bazel-bin +++ /dev/null @@ -1 +0,0 @@ -/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__/bazel-out/darwin_arm64-fastbuild/bin \ No newline at end of file diff --git a/bazel-out b/bazel-out deleted file mode 120000 index dab0101f8988f..0000000000000 --- a/bazel-out +++ /dev/null @@ -1 +0,0 @@ -/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__/bazel-out \ No newline at end of file diff --git a/bazel-testlogs b/bazel-testlogs deleted file mode 120000 index 377400ba0073b..0000000000000 --- a/bazel-testlogs +++ /dev/null @@ -1 +0,0 @@ -/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__/bazel-out/darwin_arm64-fastbuild/testlogs \ No newline at end of file diff --git a/bazel-tidb b/bazel-tidb deleted file mode 120000 index 40be33516b288..0000000000000 --- a/bazel-tidb +++ /dev/null @@ -1 +0,0 @@ -/private/var/tmp/_bazel_weizhenwang/c594c21a6a69807d82f853d23f182f0d/execroot/__main__ \ No newline at end of file