From f1aad99e7b303915783a6f94daf7c5402340feb6 Mon Sep 17 00:00:00 2001 From: Wan Kai Date: Fri, 13 Sep 2024 14:15:20 +0800 Subject: [PATCH] Fix `findEndpoint` query require `keyword` when using BanyanDB. (#12615) --- docs/en/changes/changes.md | 1 + .../oap/server/core/zipkin/ZipkinServiceSpanTraffic.java | 1 + .../plugin/banyandb/measure/BanyanDBMetadataQueryDAO.java | 2 +- test/e2e-v2/script/env | 2 +- 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/en/changes/changes.md b/docs/en/changes/changes.md index f4307a70765c..3ec2f43f3da2 100644 --- a/docs/en/changes/changes.md +++ b/docs/en/changes/changes.md @@ -63,6 +63,7 @@ * Support service level metrics aggregate when missing pod context in eBPF Access Log Receiver. * Fix query `getGlobalTopology` throw exception when didn't find any services by the given Layer. * Fix the previous analysis result missing in the ALS `k8s-mesh` analyzer. +* Fix `findEndpoint` query require `keyword` when using BanyanDB. #### UI diff --git a/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/zipkin/ZipkinServiceSpanTraffic.java b/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/zipkin/ZipkinServiceSpanTraffic.java index a1699239bd55..2681815a1e70 100644 --- a/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/zipkin/ZipkinServiceSpanTraffic.java +++ b/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/zipkin/ZipkinServiceSpanTraffic.java @@ -57,6 +57,7 @@ public class ZipkinServiceSpanTraffic extends Metrics { @Setter @Getter @Column(name = SPAN_NAME) + @BanyanDB.SeriesID(index = 1) private String spanName = Const.EMPTY_STRING; @Override diff --git a/oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/measure/BanyanDBMetadataQueryDAO.java b/oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/measure/BanyanDBMetadataQueryDAO.java index 1607f2875b49..3a73581cab14 100644 --- a/oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/measure/BanyanDBMetadataQueryDAO.java +++ b/oap-server/server-storage-plugin/storage-banyandb-plugin/src/main/java/org/apache/skywalking/oap/server/storage/plugin/banyandb/measure/BanyanDBMetadataQueryDAO.java @@ -195,7 +195,7 @@ protected void apply(MeasureQuery query) { endpoints.add(buildEndpoint(dataPoint, schema)); } - if (StringUtil.isNotEmpty(serviceId)) { + if (StringUtil.isNotEmpty(keyword)) { return endpoints.stream().filter(e -> e.getName().contains(keyword)).collect(Collectors.toList()); } return endpoints; diff --git a/test/e2e-v2/script/env b/test/e2e-v2/script/env index c461eeddaaf0..4dcf1af0991a 100644 --- a/test/e2e-v2/script/env +++ b/test/e2e-v2/script/env @@ -23,7 +23,7 @@ SW_AGENT_CLIENT_JS_COMMIT=af0565a67d382b683c1dbd94c379b7080db61449 SW_AGENT_CLIENT_JS_TEST_COMMIT=4f1eb1dcdbde3ec4a38534bf01dded4ab5d2f016 SW_KUBERNETES_COMMIT_SHA=1335f15bf821a40a7cd71448fa805f0be265afcc SW_ROVER_COMMIT=6bbd39aa701984482330d9dfb4dbaaff0527d55c -SW_BANYANDB_COMMIT=d48a810f8cca8b66d7b3b179f36090d78f46e12c +SW_BANYANDB_COMMIT=59c396870ac2d81ec81113802d54277fe070d91b SW_AGENT_PHP_COMMIT=3192c553002707d344bd6774cfab5bc61f67a1d3 SW_CTL_COMMIT=d5f3597733aa5217373986d776a3ee5ee8b3c468