You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by wu...@apache.org on 2022/05/09 23:52:06 UTC
[skywalking-satellite] branch main updated: Support transmit the eBPF Process and Profiling protocol (#110)
This is an automated email from the ASF dual-hosted git repository.
wusheng pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/skywalking-satellite.git
The following commit(s) were added to refs/heads/main by this push:
new 1b2f775 Support transmit the eBPF Process and Profiling protocol (#110)
1b2f775 is described below
commit 1b2f7751b913f8baa58423bd146ff43758704ae7
Author: mrproliu <74...@qq.com>
AuthorDate: Tue May 10 07:52:02 2022 +0800
Support transmit the eBPF Process and Profiling protocol (#110)
---
.github/workflows/e2e-native.yaml | 15 +++-
CHANGES.md | 2 +
configs/satellite_config.yaml | 84 +++++++++++++++++-----
docs/en/setup/configuration/pipe-plugins.md | 4 +-
.../transmit-log-to-kafka/satellite_config.yaml | 4 +-
.../plugins/fetcher_prometheus-metrics-fetcher.md | 2 +-
...r.md => forwarder_native-cds-grpc-forwarder.md} | 2 +-
...warder_native-ebpf-profiling-grpc-forwarder.md} | 4 +-
...md => forwarder_native-event-grpc-forwarder.md} | 2 +-
...r.md => forwarder_native-jvm-grpc-forwarder.md} | 2 +-
...r.md => forwarder_native-log-grpc-forwarder.md} | 2 +-
....md => forwarder_native-log-kafka-forwarder.md} | 2 +-
... forwarder_native-management-grpc-forwarder.md} | 2 +-
...md => forwarder_native-meter-grpc-forwarder.md} | 2 +-
... => forwarder_native-process-grpc-forwarder.md} | 4 +-
... => forwarder_native-profile-grpc-forwarder.md} | 2 +-
... => forwarder_native-tracing-grpc-forwarder.md} | 2 +-
docs/en/setup/plugins/plugin-list.md | 40 ++++++-----
...ver.md => receiver_grpc-native-cds-receiver.md} | 4 +-
...receiver_grpc-native-ebpf-profiling-receiver.md | 11 +++
...r.md => receiver_grpc-native-event-receiver.md} | 4 +-
...ver.md => receiver_grpc-native-jvm-receiver.md} | 4 +-
...ver.md => receiver_grpc-native-log-receiver.md} | 4 +-
...=> receiver_grpc-native-management-receiver.md} | 4 +-
...r.md => receiver_grpc-native-meter-receiver.md} | 4 +-
.../receiver_grpc-native-process-receiver.md | 11 +++
...md => receiver_grpc-native-profile-receiver.md} | 4 +-
...md => receiver_grpc-native-tracing-receiver.md} | 4 +-
...ver.md => receiver_http-native-log-receiver.md} | 4 +-
docs/menu.yml | 44 +++++++-----
go.mod | 2 +-
go.sum | 4 +-
internal/satellite/config/loader_test.go | 4 +-
plugins/forwarder/forwarder_repository.go | 4 ++
plugins/forwarder/grpc/nativecds/forwarder.go | 2 +-
.../forwarder.go | 56 ++++++++-------
.../forwarder/grpc/nativeevent/sync_forwarder.go | 2 +-
plugins/forwarder/grpc/nativejvm/sync_forwarder.go | 2 +-
plugins/forwarder/grpc/nativelog/forwarder.go | 2 +-
.../forwarder/grpc/nativemanagement/forwarder.go | 2 +-
plugins/forwarder/grpc/nativemeter/forwarder.go | 2 +-
.../grpc/{nativecds => nativeprocess}/forwarder.go | 47 ++++++------
plugins/forwarder/grpc/nativeprofile/forwarder.go | 2 +-
plugins/forwarder/grpc/nativetracing/forwarder.go | 2 +-
plugins/forwarder/kafka/nativelog/forwarder.go | 2 +-
plugins/receiver/grpc/nativecds/receiver.go | 2 +-
.../profiling_report_service.go | 83 +++++++++++++++++++++
.../{nativelog => nativeebpfprofiling}/receiver.go | 25 +++----
.../grpc/nativeebpfprofiling/receiver_test.go | 77 ++++++++++++++++++++
plugins/receiver/grpc/nativeevent/receiver.go | 2 +-
plugins/receiver/grpc/nativejvm/receiver.go | 2 +-
plugins/receiver/grpc/nativelog/receiver.go | 2 +-
plugins/receiver/grpc/nativemanagement/receiver.go | 2 +-
plugins/receiver/grpc/nativemeter/receiver.go | 2 +-
.../grpc/nativeprocess/process_report_service.go | 67 +++++++++++++++++
.../grpc/{nativelog => nativeprocess}/receiver.go | 25 +++----
.../receiver/grpc/nativeprocess/receiver_test.go | 63 ++++++++++++++++
plugins/receiver/grpc/nativeprofile/receiver.go | 2 +-
plugins/receiver/grpc/nativetracing/receiver.go | 2 +-
plugins/receiver/http/nativcelog/receiver.go | 2 +-
plugins/receiver/receiver_repository.go | 4 ++
test/e2e/base/base-compose.yml | 4 +-
test/e2e/base/env | 7 +-
.../prepare/setup-e2e-shell/install-swctl.sh | 16 +++--
test/e2e/case/istio/als/e2e.yaml | 4 --
.../case/istio/als/expected/service-instance.yml | 1 +
test/e2e/case/istio/als/expected/service.yml | 44 +++++++++---
test/e2e/case/istio/metrics/e2e.yaml | 84 +++++++++++-----------
.../istio/metrics/expected/service-instance.yml | 1 +
test/e2e/case/istio/metrics/expected/service.yml | 64 +++++++++++------
test/e2e/case/native-ebpf/Dockerfile.sqrt | 23 ++++++
test/e2e/case/native-ebpf/docker-compose.yml | 77 ++++++++++++++++++++
test/e2e/case/native-ebpf/e2e.yaml | 63 ++++++++++++++++
.../expected/instance.yml} | 7 +-
.../expected/process-estimate-scale.yml} | 8 +--
.../expected/process.yml} | 28 ++++++--
.../expected/profiling-create-prepare.yml} | 13 ++--
.../expected/profiling-create.yml} | 10 +--
.../expected/profiling-schedule-list.yml} | 45 +++++++-----
.../expected/profiling-task-list.yml} | 20 ++++--
.../expected/service.yml} | 14 ++--
.../profiling-analysis.yml} | 17 +++--
test/e2e/case/native-ebpf/sqrt.go | 32 +++++++++
test/e2e/case/native-protocols/e2e.yaml | 20 +++---
.../case/native-protocols/expected/event-list.yml | 1 +
.../case/native-protocols/expected/logs-list.yml | 4 +-
.../native-protocols/expected/service-instance.yml | 3 +-
.../e2e/case/native-protocols/expected/service.yml | 8 +++
88 files changed, 1050 insertions(+), 344 deletions(-)
diff --git a/.github/workflows/e2e-native.yaml b/.github/workflows/e2e-native.yaml
index 34a98ef..d96b608 100644
--- a/.github/workflows/e2e-native.yaml
+++ b/.github/workflows/e2e-native.yaml
@@ -23,7 +23,15 @@ on:
jobs:
NativeProtocolsE2E:
- name: Native Management/JVM/Tracing/Meter/Event/Log/Profile/CDS
+ strategy:
+ matrix:
+ test:
+ - name: Native Management/JVM/Tracing/Meter/Event/Log/Profile/CDS
+ config: test/e2e/case/native-protocols/e2e.yaml
+ - name: Native Process/EBPF Profiling
+ config: test/e2e/case/native-ebpf/e2e.yaml
+ fail-fast: true
+ name: Native E2E test
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.17
@@ -40,9 +48,10 @@ jobs:
cd test/e2e/base
./mvnw --batch-mode -f provider/pom.xml clean package -Dsw.version=8.7.0
./mvnw --batch-mode -f consumer/pom.xml clean package -Dsw.version=8.7.0
- - uses: apache/skywalking-infra-e2e@45584853d6f660102c523b1e9cb5815d12ae55d3
+ - name: ${{ matrix.test.name }}
+ uses: apache/skywalking-infra-e2e@45584853d6f660102c523b1e9cb5815d12ae55d3
with:
- e2e-file: test/e2e/case/native-protocols/e2e.yaml
+ e2e-file: $GITHUB_WORKSPACE/${{ matrix.test.config }}
- uses: actions/upload-artifact@v2
if: ${{ failure() }}
name: Upload Logs
diff --git a/CHANGES.md b/CHANGES.md
index 5c81c26..b37b862 100644
--- a/CHANGES.md
+++ b/CHANGES.md
@@ -6,6 +6,8 @@ Release Notes.
------------------
#### Features
* Add the compat protocol receiver for the old version of agents.
+* Support transmit the native eBPF Process and Profiling protocol.
+* Change the name of plugin that is not well-named.
#### Bug Fixes
* Fix Metadata lost in the Native Meter protocol.
diff --git a/configs/satellite_config.yaml b/configs/satellite_config.yaml
index 3c57817..09dbfc9 100644
--- a/configs/satellite_config.yaml
+++ b/configs/satellite_config.yaml
@@ -138,7 +138,7 @@ pipes:
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativelog-receiver"
+ plugin_name: "grpc-native-log-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -158,13 +158,13 @@ pipes:
min_flush_events: ${SATELLITE_LOGPIPE_SENDER_MIN_FLUSH_EVENTS:100}
client_name: grpc-client
forwarders:
- - plugin_name: nativelog-grpc-forwarder
+ - plugin_name: native-log-grpc-forwarder
- common_config:
pipe_name: managementpipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativemanagement-receiver"
+ plugin_name: "grpc-native-management-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -184,13 +184,13 @@ pipes:
min_flush_events: ${SATELLITE_LOGMANAGEMENT_SENDER_MIN_FLUSH_EVENTS:1}
client_name: grpc-client
forwarders:
- - plugin_name: nativemanagement-grpc-forwarder
+ - plugin_name: native-management-grpc-forwarder
- common_config:
pipe_name: tracingpipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativetracing-receiver"
+ plugin_name: "grpc-native-tracing-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -210,13 +210,13 @@ pipes:
min_flush_events: ${SATELLITE_TRACINGPIPE_SENDER_MIN_FLUSH_EVENTS:1}
client_name: grpc-client
forwarders:
- - plugin_name: nativetracing-grpc-forwarder
+ - plugin_name: native-tracing-grpc-forwarder
- common_config:
pipe_name: profilepipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativeprofile-receiver"
+ plugin_name: "grpc-native-profile-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -236,13 +236,13 @@ pipes:
min_flush_events: ${SATELLITE_PROFILEPIPE_SENDER_MIN_FLUSH_EVENTS:1}
client_name: grpc-client
forwarders:
- - plugin_name: nativeprofile-grpc-forwarder
+ - plugin_name: native-profile-grpc-forwarder
- common_config:
pipe_name: cdspipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativecds-receiver"
+ plugin_name: "grpc-native-cds-receiver"
queue:
plugin_name: "none-queue"
processor:
@@ -252,13 +252,13 @@ pipes:
plugin_name: none-fallbacker
client_name: grpc-client
forwarders:
- - plugin_name: nativecds-grpc-forwarder
+ - plugin_name: native-cds-grpc-forwarder
- common_config:
pipe_name: eventpipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativeevent-receiver"
+ plugin_name: "grpc-native-event-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -278,13 +278,13 @@ pipes:
min_flush_events: ${SATELLITE_EVENTPIPE_SENDER_MIN_FLUSH_EVENTS:1}
client_name: grpc-client
forwarders:
- - plugin_name: nativeevent-grpc-forwarder
+ - plugin_name: native-event-grpc-forwarder
- common_config:
pipe_name: jvmpipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativejvm-receiver"
+ plugin_name: "grpc-native-jvm-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -304,13 +304,13 @@ pipes:
min_flush_events: ${SATELLITE_JVMPIPE_SENDER_MIN_FLUSH_EVENTS:1}
client_name: grpc-client
forwarders:
- - plugin_name: nativejvm-grpc-forwarder
+ - plugin_name: native-jvm-grpc-forwarder
- common_config:
pipe_name: meterpipe
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativemeter-receiver"
+ plugin_name: "grpc-native-meter-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -330,7 +330,7 @@ pipes:
min_flush_events: ${SATELLITE_METERPIPE_SENDER_MIN_FLUSH_EVENTS:1}
client_name: grpc-client
forwarders:
- - plugin_name: nativemeter-grpc-forwarder
+ - plugin_name: native-meter-grpc-forwarder
# The LRU policy cache size for hosting routine rules of service instance.
routing_rule_lru_cache_size: ${SATELLITE_METERPIPE_FORWARD_ROUTING_RULE_LRU_CACHE_SIZE:5000}
# The TTL of the LRU cache size for hosting routine rules of service instance.
@@ -455,3 +455,55 @@ pipes:
client_name: grpc-client
forwarders:
- plugin_name: envoy-metrics-v3-grpc-forwarder
+ - common_config:
+ pipe_name: processpipe
+ gatherer:
+ server_name: "grpc-server"
+ receiver:
+ plugin_name: "grpc-native-process-receiver"
+ queue:
+ plugin_name: "memory-queue"
+ # The maximum buffer event size.
+ event_buffer_size: ${SATELLITE_QUEUE_EVENT_BUFFER_SIZE:5000}
+ # The partition count of queue.
+ partition: ${SATELLITE_QUEUE_PARTITION:4}
+ processor:
+ filters:
+ sender:
+ fallbacker:
+ plugin_name: none-fallbacker
+ # The time interval between two flush operations. And the time unit is millisecond.
+ flush_time: ${SATELLITE_PROCESSPIPE_SENDER_FLUSH_TIME:1000}
+ # The maximum buffer elements.
+ max_buffer_size: ${SATELLITE_PROCESSPIPE_SENDER_MAX_BUFFER_SIZE:200}
+ # The minimum flush elements.
+ min_flush_events: ${SATELLITE_PROCESSPIPE_SENDER_MIN_FLUSH_EVENTS:1}
+ client_name: grpc-client
+ forwarders:
+ - plugin_name: native-process-grpc-forwarder
+ - common_config:
+ pipe_name: ebpf-profilingpipe
+ gatherer:
+ server_name: "grpc-server"
+ receiver:
+ plugin_name: "grpc-native-ebpf-profiling-receiver"
+ queue:
+ plugin_name: "memory-queue"
+ # The maximum buffer event size.
+ event_buffer_size: ${SATELLITE_QUEUE_EVENT_BUFFER_SIZE:5000}
+ # The partition count of queue.
+ partition: ${SATELLITE_QUEUE_PARTITION:4}
+ processor:
+ filters:
+ sender:
+ fallbacker:
+ plugin_name: none-fallbacker
+ # The time interval between two flush operations. And the time unit is millisecond.
+ flush_time: ${SATELLITE_EBPFPROFILINGPIPE_SENDER_FLUSH_TIME:1000}
+ # The maximum buffer elements.
+ max_buffer_size: ${SATELLITE_EBPFPROFILINGPIPE_SENDER_MAX_BUFFER_SIZE:200}
+ # The minimum flush elements.
+ min_flush_events: ${SATELLITE_EBPFPROFILINGPIPE_SENDER_MIN_FLUSH_EVENTS:1}
+ client_name: grpc-client
+ forwarders:
+ - plugin_name: native-ebpf-profiling-grpc-forwarder
diff --git a/docs/en/setup/configuration/pipe-plugins.md b/docs/en/setup/configuration/pipe-plugins.md
index eb47cb7..b3b30c5 100644
--- a/docs/en/setup/configuration/pipe-plugins.md
+++ b/docs/en/setup/configuration/pipe-plugins.md
@@ -46,7 +46,7 @@ pipes:
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativelog-receiver"
+ plugin_name: "grpc-native-log-receiver"
queue:
plugin_name: "mmap-queue"
segment_size: ${SATELLITE_MMAP_QUEUE_SIZE:524288}
@@ -62,6 +62,6 @@ pipes:
min_flush_events: ${SATELLITE_PIPE1_SENDER_MIN_FLUSH_EVENTS:100}
client_name: kafka-client
forwarders:
- - plugin_name: nativelog-kafka-forwarder
+ - plugin_name: native-log-kafka-forwarder
topic: ${SATELLITE_NATIVELOG-TOPIC:log-topic}
```
\ No newline at end of file
diff --git a/docs/en/setup/examples/feature/transmit-log-to-kafka/satellite_config.yaml b/docs/en/setup/examples/feature/transmit-log-to-kafka/satellite_config.yaml
index 1498c46..e3d1ee1 100644
--- a/docs/en/setup/examples/feature/transmit-log-to-kafka/satellite_config.yaml
+++ b/docs/en/setup/examples/feature/transmit-log-to-kafka/satellite_config.yaml
@@ -70,7 +70,7 @@ pipes:
gatherer:
server_name: "grpc-server"
receiver:
- plugin_name: "grpc-nativelog-receiver"
+ plugin_name: "grpc-native-log-receiver"
queue:
plugin_name: "memory-queue"
# The maximum buffer event size.
@@ -88,6 +88,6 @@ pipes:
min_flush_events: ${SATELLITE_LOGPIPE_SENDER_MIN_FLUSH_EVENTS:100}
client_name: kafka-client
forwarders:
- - plugin_name: nativelog-kafka-forwarder
+ - plugin_name: native-log-kafka-forwarder
# The remote kafka topic.
topic: ${SATELLITE_NATIVELOG-TOPIC:log-topic}
diff --git a/docs/en/setup/plugins/fetcher_prometheus-metrics-fetcher.md b/docs/en/setup/plugins/fetcher_prometheus-metrics-fetcher.md
index bce387d..fbf526b 100755
--- a/docs/en/setup/plugins/fetcher_prometheus-metrics-fetcher.md
+++ b/docs/en/setup/plugins/fetcher_prometheus-metrics-fetcher.md
@@ -2,7 +2,7 @@
## Description
This is a fetcher for Skywalking prometheus metrics format, which will translate Prometheus metrics to Skywalking meter system.
## Support Forwarders
- - [nativemeter-grpc-forwarder](forwarder_nativemeter-grpc-forwarder.md)
+ - [native-meter-grpc-forwarder](forwarder_native-meter-grpc-forwarder.md)
## DefaultConfig
```yaml
# scrape_configs is the scrape configuration of prometheus
diff --git a/docs/en/setup/plugins/forwarder_nativecds-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-cds-grpc-forwarder.md
similarity index 85%
rename from docs/en/setup/plugins/forwarder_nativecds-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-cds-grpc-forwarder.md
index 57c1b11..90d2894 100755
--- a/docs/en/setup/plugins/forwarder_nativecds-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-cds-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativecds-grpc-forwarder
+# Forwarder/native-cds-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native Configuration Discovery Service protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativemanagement-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-ebpf-profiling-grpc-forwarder.md
similarity index 70%
copy from docs/en/setup/plugins/forwarder_nativemanagement-grpc-forwarder.md
copy to docs/en/setup/plugins/forwarder_native-ebpf-profiling-grpc-forwarder.md
index 80367b8..dd96903 100755
--- a/docs/en/setup/plugins/forwarder_nativemanagement-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-ebpf-profiling-grpc-forwarder.md
@@ -1,6 +1,6 @@
-# Forwarder/nativemanagement-grpc-forwarder
+# Forwarder/native-ebpf-profiling-grpc-forwarder
## Description
-This is a synchronization grpc forwarder with the SkyWalking native management protocol.
+This is a synchronization grpc forwarder with the SkyWalking native process protocol.
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/forwarder_nativeevent-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-event-grpc-forwarder.md
similarity index 82%
rename from docs/en/setup/plugins/forwarder_nativeevent-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-event-grpc-forwarder.md
index 2dcd0f2..9ebed20 100755
--- a/docs/en/setup/plugins/forwarder_nativeevent-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-event-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativeevent-grpc-forwarder
+# Forwarder/native-event-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native event protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativejvm-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-jvm-grpc-forwarder.md
similarity index 85%
rename from docs/en/setup/plugins/forwarder_nativejvm-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-jvm-grpc-forwarder.md
index 09f9c9a..784d441 100755
--- a/docs/en/setup/plugins/forwarder_nativejvm-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-jvm-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativejvm-grpc-forwarder
+# Forwarder/native-jvm-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native Configuration Discovery Service protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativelog-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-log-grpc-forwarder.md
similarity index 83%
rename from docs/en/setup/plugins/forwarder_nativelog-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-log-grpc-forwarder.md
index 309ab77..a526124 100755
--- a/docs/en/setup/plugins/forwarder_nativelog-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-log-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativelog-grpc-forwarder
+# Forwarder/native-log-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native log protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativelog-kafka-forwarder.md b/docs/en/setup/plugins/forwarder_native-log-kafka-forwarder.md
similarity index 87%
rename from docs/en/setup/plugins/forwarder_nativelog-kafka-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-log-kafka-forwarder.md
index 941e9da..8e02f36 100755
--- a/docs/en/setup/plugins/forwarder_nativelog-kafka-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-log-kafka-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativelog-kafka-forwarder
+# Forwarder/native-log-kafka-forwarder
## Description
This is a synchronization Kafka forwarder with the SkyWalking native log protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativemanagement-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-management-grpc-forwarder.md
similarity index 81%
rename from docs/en/setup/plugins/forwarder_nativemanagement-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-management-grpc-forwarder.md
index 80367b8..aee7b56 100755
--- a/docs/en/setup/plugins/forwarder_nativemanagement-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-management-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativemanagement-grpc-forwarder
+# Forwarder/native-management-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native management protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativemeter-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-meter-grpc-forwarder.md
similarity index 94%
rename from docs/en/setup/plugins/forwarder_nativemeter-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-meter-grpc-forwarder.md
index 8939644..01892cf 100755
--- a/docs/en/setup/plugins/forwarder_nativemeter-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-meter-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativemeter-grpc-forwarder
+# Forwarder/native-meter-grpc-forwarder
## Description
This is a synchronization meter grpc forwarder with the SkyWalking meter protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativetracing-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-process-grpc-forwarder.md
similarity index 72%
copy from docs/en/setup/plugins/forwarder_nativetracing-grpc-forwarder.md
copy to docs/en/setup/plugins/forwarder_native-process-grpc-forwarder.md
index 6f986ec..f587f1f 100755
--- a/docs/en/setup/plugins/forwarder_nativetracing-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-process-grpc-forwarder.md
@@ -1,6 +1,6 @@
-# Forwarder/nativetracing-grpc-forwarder
+# Forwarder/native-process-grpc-forwarder
## Description
-This is a synchronization grpc forwarder with the SkyWalking native tracing protocol.
+This is a synchronization grpc forwarder with the SkyWalking native process protocol.
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/forwarder_nativeprofile-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-profile-grpc-forwarder.md
similarity index 81%
rename from docs/en/setup/plugins/forwarder_nativeprofile-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-profile-grpc-forwarder.md
index 56b4343..d241e9c 100755
--- a/docs/en/setup/plugins/forwarder_nativeprofile-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-profile-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativeprofile-grpc-forwarder
+# Forwarder/native-profile-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native log protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/forwarder_nativetracing-grpc-forwarder.md b/docs/en/setup/plugins/forwarder_native-tracing-grpc-forwarder.md
similarity index 82%
rename from docs/en/setup/plugins/forwarder_nativetracing-grpc-forwarder.md
rename to docs/en/setup/plugins/forwarder_native-tracing-grpc-forwarder.md
index 6f986ec..6a6f730 100755
--- a/docs/en/setup/plugins/forwarder_nativetracing-grpc-forwarder.md
+++ b/docs/en/setup/plugins/forwarder_native-tracing-grpc-forwarder.md
@@ -1,4 +1,4 @@
-# Forwarder/nativetracing-grpc-forwarder
+# Forwarder/native-tracing-grpc-forwarder
## Description
This is a synchronization grpc forwarder with the SkyWalking native tracing protocol.
## DefaultConfig
diff --git a/docs/en/setup/plugins/plugin-list.md b/docs/en/setup/plugins/plugin-list.md
index b5a6dcb..e1c7496 100755
--- a/docs/en/setup/plugins/plugin-list.md
+++ b/docs/en/setup/plugins/plugin-list.md
@@ -13,15 +13,17 @@
- [Envoy ALS v3 GRPC Forwarder](./forwarder_envoy-als-v3-grpc-forwarder.md)
- [Envoy Metrics v2 GRPC Forwarder](./forwarder_envoy-metrics-v2-grpc-forwarder.md)
- [Envoy Metrics v3 GRPC Forwarder](./forwarder_envoy-metrics-v3-grpc-forwarder.md)
- - [Native CDS GRPC Forwarder](./forwarder_nativecds-grpc-forwarder.md)
- - [Native Event GRPC Forwarder](./forwarder_nativeevent-grpc-forwarder.md)
- - [Native JVM GRPC Forwarder](./forwarder_nativejvm-grpc-forwarder.md)
- - [Native Log GRPC Forwarder](./forwarder_nativelog-grpc-forwarder.md)
- - [Native Log Kafka Forwarder](./forwarder_nativelog-kafka-forwarder.md)
- - [Native Management GRPC Forwarder](./forwarder_nativemanagement-grpc-forwarder.md)
- - [Native Meter GRPC Forwarder](./forwarder_nativemeter-grpc-forwarder.md)
- - [Native Profile GRPC Forwarder](./forwarder_nativeprofile-grpc-forwarder.md)
- - [Native Tracing GRPC Forwarder](./forwarder_nativetracing-grpc-forwarder.md)
+ - [Native CDS GRPC Forwarder](./forwarder_native-cds-grpc-forwarder.md)
+ - [Native EBPF Profiling GRPC Forwarder](./forwarder_native-ebpf-profiling-grpc-forwarder.md)
+ - [Native Event GRPC Forwarder](./forwarder_native-event-grpc-forwarder.md)
+ - [Native JVM GRPC Forwarder](./forwarder_native-jvm-grpc-forwarder.md)
+ - [Native Log GRPC Forwarder](./forwarder_native-log-grpc-forwarder.md)
+ - [Native Log Kafka Forwarder](./forwarder_native-log-kafka-forwarder.md)
+ - [Native Management GRPC Forwarder](./forwarder_native-management-grpc-forwarder.md)
+ - [Native Meter GRPC Forwarder](./forwarder_native-meter-grpc-forwarder.md)
+ - [Native Process GRPC Forwarder](./forwarder_native-process-grpc-forwarder.md)
+ - [Native Profile GRPC Forwarder](./forwarder_native-profile-grpc-forwarder.md)
+ - [Native Tracing GRPC Forwarder](./forwarder_native-tracing-grpc-forwarder.md)
- Parser
- Queue
- [Memory Queue](./queue_memory-queue.md)
@@ -32,15 +34,17 @@
- [GRPC Envoy ALS v3 Receiver](./receiver_grpc-envoy-als-v3-receiver.md)
- [GRPC Envoy Metrics v2 Receiver](./receiver_grpc-envoy-metrics-v2-receiver.md)
- [GRPC Envoy Metrics v3 Receiver](./receiver_grpc-envoy-metrics-v3-receiver.md)
- - [GRPC Native CDS Receiver](./receiver_grpc-nativecds-receiver.md)
- - [GRPC Native Event Receiver](./receiver_grpc-nativeevent-receiver.md)
- - [GRPC Native JVM Receiver](./receiver_grpc-nativejvm-receiver.md)
- - [GRPC Native Log Receiver](./receiver_grpc-nativelog-receiver.md)
- - [GRPC Native Management Receiver](./receiver_grpc-nativemanagement-receiver.md)
- - [GRPC Native Meter Receiver](./receiver_grpc-nativemeter-receiver.md)
- - [GRPC Native Profile Receiver](./receiver_grpc-nativeprofile-receiver.md)
- - [GRPC Native Tracing Receiver](./receiver_grpc-nativetracing-receiver.md)
- - [HTTP Native Log Receiver](./receiver_http-nativelog-receiver.md)
+ - [GRPC Native CDS Receiver](./receiver_grpc-native-cds-receiver.md)
+ - [GRPC Native EBFP Profiling Receiver](./receiver_grpc-native-ebpf-profiling-receiver.md)
+ - [GRPC Native Event Receiver](./receiver_grpc-native-event-receiver.md)
+ - [GRPC Native JVM Receiver](./receiver_grpc-native-jvm-receiver.md)
+ - [GRPC Native Log Receiver](./receiver_grpc-native-log-receiver.md)
+ - [GRPC Native Management Receiver](./receiver_grpc-native-management-receiver.md)
+ - [GRPC Native Meter Receiver](./receiver_grpc-native-meter-receiver.md)
+ - [GRPC Native Process Receiver](./receiver_grpc-native-process-receiver.md)
+ - [GRPC Native Profile Receiver](./receiver_grpc-native-profile-receiver.md)
+ - [GRPC Native Tracing Receiver](./receiver_grpc-native-tracing-receiver.md)
+ - [HTTP Native Log Receiver](./receiver_http-native-log-receiver.md)
- Server
- [GRPC Server](./server_grpc-server.md)
- [HTTP Server](./server_http-server.md)
diff --git a/docs/en/setup/plugins/receiver_grpc-nativecds-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-cds-receiver.md
similarity index 76%
rename from docs/en/setup/plugins/receiver_grpc-nativecds-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-cds-receiver.md
index 68b7313..8eed9c8 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativecds-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-cds-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativecds-receiver
+# Receiver/grpc-native-cds-receiver
## Description
This is a receiver for SkyWalking native Configuration Discovery Service format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/language-agent/ConfigurationDiscoveryService.proto.
## Support Forwarders
- - [nativecds-grpc-forwarder](forwarder_nativecds-grpc-forwarder.md)
+ - [native-cds-grpc-forwarder](forwarder_native-cds-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-native-ebpf-profiling-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-ebpf-profiling-receiver.md
new file mode 100755
index 0000000..052642f
--- /dev/null
+++ b/docs/en/setup/plugins/receiver_grpc-native-ebpf-profiling-receiver.md
@@ -0,0 +1,11 @@
+# Receiver/grpc-native-ebpf-profiling-receiver
+## Description
+This is a receiver for SkyWalking native process format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/ebpf/profiling/Process.proto.
+## Support Forwarders
+ - [native-ebpf-profiling-grpc-forwarder](forwarder_native-ebpf-profiling-grpc-forwarder.md)
+## DefaultConfig
+```yaml```
+## Configuration
+|Name|Type|Description|
+|----|----|-----------|
+
diff --git a/docs/en/setup/plugins/receiver_grpc-nativemeter-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-event-receiver.md
similarity index 72%
rename from docs/en/setup/plugins/receiver_grpc-nativemeter-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-event-receiver.md
index d565a09..9c204ae 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativemeter-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-event-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativemeter-receiver
+# Receiver/grpc-native-event-receiver
## Description
This is a receiver for SkyWalking native meter format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/event/Event.proto.
## Support Forwarders
- - [nativemeter-grpc-forwarder](forwarder_nativemeter-grpc-forwarder.md)
+ - [native-event-grpc-forwarder](forwarder_native-event-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-nativejvm-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-jvm-receiver.md
similarity index 74%
rename from docs/en/setup/plugins/receiver_grpc-nativejvm-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-jvm-receiver.md
index 0f75649..feb0f7a 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativejvm-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-jvm-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativejvm-receiver
+# Receiver/grpc-native-jvm-receiver
## Description
This is a receiver for SkyWalking native jvm format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/language-agent/JVMMetric.proto.
## Support Forwarders
- - [nativejvm-grpc-forwarder](forwarder_nativejvm-grpc-forwarder.md)
+ - [native-jvm-grpc-forwarder](forwarder_native-jvm-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-nativelog-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-log-receiver.md
similarity index 73%
rename from docs/en/setup/plugins/receiver_grpc-nativelog-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-log-receiver.md
index 47572e8..1fb57a0 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativelog-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-log-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativelog-receiver
+# Receiver/grpc-native-log-receiver
## Description
This is a receiver for SkyWalking native logging format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/logging/Logging.proto.
## Support Forwarders
- - [nativelog-grpc-forwarder](forwarder_nativelog-grpc-forwarder.md)
+ - [native-log-grpc-forwarder](forwarder_native-log-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-nativemanagement-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-management-receiver.md
similarity index 70%
rename from docs/en/setup/plugins/receiver_grpc-nativemanagement-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-management-receiver.md
index a0b4253..9632dae 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativemanagement-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-management-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativemanagement-receiver
+# Receiver/grpc-native-management-receiver
## Description
This is a receiver for SkyWalking native management format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/management/Management.proto.
## Support Forwarders
- - [nativemanagement-grpc-forwarder](forwarder_nativemanagement-grpc-forwarder.md)
+ - [native-management-grpc-forwarder](forwarder_native-management-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-nativeevent-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-meter-receiver.md
similarity index 72%
rename from docs/en/setup/plugins/receiver_grpc-nativeevent-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-meter-receiver.md
index caacd67..fdf58f4 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativeevent-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-meter-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativeevent-receiver
+# Receiver/grpc-native-meter-receiver
## Description
This is a receiver for SkyWalking native meter format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/event/Event.proto.
## Support Forwarders
- - [nativeevent-grpc-forwarder](forwarder_nativeevent-grpc-forwarder.md)
+ - [native-meter-grpc-forwarder](forwarder_native-meter-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-native-process-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-process-receiver.md
new file mode 100755
index 0000000..396ff7b
--- /dev/null
+++ b/docs/en/setup/plugins/receiver_grpc-native-process-receiver.md
@@ -0,0 +1,11 @@
+# Receiver/grpc-native-process-receiver
+## Description
+This is a receiver for SkyWalking native process format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/ebpf/profiling/Process.proto.
+## Support Forwarders
+ - [native-process-grpc-forwarder](forwarder_native-process-grpc-forwarder.md)
+## DefaultConfig
+```yaml```
+## Configuration
+|Name|Type|Description|
+|----|----|-----------|
+
diff --git a/docs/en/setup/plugins/receiver_grpc-nativeprofile-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-profile-receiver.md
similarity index 71%
rename from docs/en/setup/plugins/receiver_grpc-nativeprofile-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-profile-receiver.md
index f932292..f72e1b6 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativeprofile-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-profile-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativeprofile-receiver
+# Receiver/grpc-native-profile-receiver
## Description
This is a receiver for SkyWalking native profile format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/profile/Profile.proto.
## Support Forwarders
- - [nativeprofile-grpc-forwarder](forwarder_nativeprofile-grpc-forwarder.md)
+ - [native-profile-grpc-forwarder](forwarder_native-profile-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_grpc-nativetracing-receiver.md b/docs/en/setup/plugins/receiver_grpc-native-tracing-receiver.md
similarity index 72%
rename from docs/en/setup/plugins/receiver_grpc-nativetracing-receiver.md
rename to docs/en/setup/plugins/receiver_grpc-native-tracing-receiver.md
index f4914c7..1e01231 100755
--- a/docs/en/setup/plugins/receiver_grpc-nativetracing-receiver.md
+++ b/docs/en/setup/plugins/receiver_grpc-native-tracing-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/grpc-nativetracing-receiver
+# Receiver/grpc-native-tracing-receiver
## Description
This is a receiver for SkyWalking native tracing format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/language-agent/Tracing.proto.
## Support Forwarders
- - [nativetracing-grpc-forwarder](forwarder_nativetracing-grpc-forwarder.md)
+ - [native-tracing-grpc-forwarder](forwarder_native-tracing-grpc-forwarder.md)
## DefaultConfig
```yaml```
## Configuration
diff --git a/docs/en/setup/plugins/receiver_http-nativelog-receiver.md b/docs/en/setup/plugins/receiver_http-native-log-receiver.md
similarity index 80%
rename from docs/en/setup/plugins/receiver_http-nativelog-receiver.md
rename to docs/en/setup/plugins/receiver_http-native-log-receiver.md
index 55b6a1c..cd3aa18 100755
--- a/docs/en/setup/plugins/receiver_http-nativelog-receiver.md
+++ b/docs/en/setup/plugins/receiver_http-native-log-receiver.md
@@ -1,8 +1,8 @@
-# Receiver/http-nativelog-receiver
+# Receiver/http-native-log-receiver
## Description
This is a receiver for SkyWalking http logging format, which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/logging/Logging.proto.
## Support Forwarders
- - [nativelog-grpc-forwarder](forwarder_nativelog-grpc-forwarder.md)
+ - [native-log-grpc-forwarder](forwarder_native-log-grpc-forwarder.md)
## DefaultConfig
```yaml
# The native log request URI.
diff --git a/docs/menu.yml b/docs/menu.yml
index 25294b5..fe5ac6a 100644
--- a/docs/menu.yml
+++ b/docs/menu.yml
@@ -96,23 +96,27 @@ catalog:
- name: Envoy Metrics v3 GRPC Forwarder
path: /en/setup/plugins/forwarder_envoy-metrics-v3-grpc-forwarder
- name: Native CDS GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativecds-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-cds-grpc-forwarder
+ - name: Native EBPF Profiling GRPC Forwarder
+ path: /en/setup/plugins/forwarder_native-ebpf-profiling-grpc-forwarder
- name: Native Event GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativeevent-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-event-grpc-forwarder
- name: Native JVM GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativejvm-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-jvm-grpc-forwarder
- name: Native Log GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativelog-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-log-grpc-forwarder
- name: Native Log Kafka Forwarder
- path: /en/setup/plugins/forwarder_nativelog-kafka-forwarder
+ path: /en/setup/plugins/forwarder_native-log-kafka-forwarder
- name: Native Management GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativemanagement-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-management-grpc-forwarder
- name: Native Meter GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativemeter-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-meter-grpc-forwarder
+ - name: Native Process GRPC Forwarder
+ path: /en/setup/plugins/forwarder_native-process-grpc-forwarder
- name: Native Profile GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativeprofile-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-profile-grpc-forwarder
- name: Native Tracing GRPC Forwarder
- path: /en/setup/plugins/forwarder_nativetracing-grpc-forwarder
+ path: /en/setup/plugins/forwarder_native-tracing-grpc-forwarder
- name: Queue
catalog:
- name: Memory Queue
@@ -132,23 +136,27 @@ catalog:
- name: GRPC Envoy Metrics v3 Receiver
path: /en/setup/plugins/receiver_grpc-envoy-metrics-v3-receiver
- name: GRPC Native CDS Receiver
- path: /en/setup/plugins/receiver_grpc-nativecds-receiver
+ path: /en/setup/plugins/receiver_grpc-native-cds-receiver
+ - name: GRPC Native EBFP Profiling Receiver
+ path: /en/setup/plugins/receiver_grpc-native-ebpf-profiling-receiver
- name: GRPC Native Event Receiver
- path: /en/setup/plugins/receiver_grpc-nativeevent-receiver
+ path: /en/setup/plugins/receiver_grpc-native-event-receiver
- name: GRPC Native JVM Receiver
- path: /en/setup/plugins/receiver_grpc-nativejvm-receiver
+ path: /en/setup/plugins/receiver_grpc-native-jvm-receiver
- name: GRPC Native Log Receiver
- path: /en/setup/plugins/receiver_grpc-nativelog-receiver
+ path: /en/setup/plugins/receiver_grpc-native-log-receiver
- name: GRPC Native Management Receiver
- path: /en/setup/plugins/receiver_grpc-nativemanagement-receiver
+ path: /en/setup/plugins/receiver_grpc-native-management-receiver
- name: GRPC Native Meter Receiver
- path: /en/setup/plugins/receiver_grpc-nativemeter-receiver
+ path: /en/setup/plugins/receiver_grpc-native-meter-receiver
+ - name: GRPC Native Process Receiver
+ path: /en/setup/plugins/receiver_grpc-native-process-receiver
- name: GRPC Native Profile Receiver
- path: /en/setup/plugins/receiver_grpc-nativeprofile-receiver
+ path: /en/setup/plugins/receiver_grpc-native-profile-receiver
- name: GRPC Native Tracing Receiver
- path: /en/setup/plugins/receiver_grpc-nativetracing-receiver
+ path: /en/setup/plugins/receiver_grpc-native-tracing-receiver
- name: HTTP Native Log Receiver
- path: /en/setup/plugins/receiver_http-nativelog-receiver
+ path: /en/setup/plugins/receiver_http-native-log-receiver
- name: Server
catalog:
- name: GRPC Server
diff --git a/go.mod b/go.mod
index 05b9b0d..0a69ce5 100644
--- a/go.mod
+++ b/go.mod
@@ -22,7 +22,7 @@ require (
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b
gotest.tools v2.2.0+incompatible
k8s.io/apimachinery v0.20.6
- skywalking.apache.org/repo/goapi v0.0.0-20220402141816-76988aaeab46
+ skywalking.apache.org/repo/goapi v0.0.0-20220509071845-6e916aff70cc
)
require (
diff --git a/go.sum b/go.sum
index bb62b24..c0c1288 100644
--- a/go.sum
+++ b/go.sum
@@ -1724,6 +1724,6 @@ sigs.k8s.io/structured-merge-diff/v4 v4.0.3/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK
sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
-skywalking.apache.org/repo/goapi v0.0.0-20220402141816-76988aaeab46 h1:c06FRvU+wwM0+Uk6EDbVT1rN8qp+YqHHCdW7CrLnDOg=
-skywalking.apache.org/repo/goapi v0.0.0-20220402141816-76988aaeab46/go.mod h1:uWwwvhcwe2MD/nJCg0c1EE/eL6KzaBosLHDfMFoEJ30=
+skywalking.apache.org/repo/goapi v0.0.0-20220509071845-6e916aff70cc h1:KHqO5RypI9EwmuhLNcJC9SG9ZArBisCkSzWhONzgQzM=
+skywalking.apache.org/repo/goapi v0.0.0-20220509071845-6e916aff70cc/go.mod h1:uWwwvhcwe2MD/nJCg0c1EE/eL6KzaBosLHDfMFoEJ30=
sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU=
diff --git a/internal/satellite/config/loader_test.go b/internal/satellite/config/loader_test.go
index ff52c9e..482574c 100644
--- a/internal/satellite/config/loader_test.go
+++ b/internal/satellite/config/loader_test.go
@@ -156,7 +156,7 @@ func pipes() []*PipeConfig {
PipeName: "logpipe",
},
ReceiverConfig: plugin.Config{
- "plugin_name": "grpc-nativelog-receiver",
+ "plugin_name": "grpc-native-log-receiver",
"commonfields_pipe_name": "logpipe",
},
QueueConfig: plugin.Config{
@@ -185,7 +185,7 @@ func pipes() []*PipeConfig {
ClientName: "grpc-client",
ForwardersConfig: []plugin.Config{
{
- "plugin_name": "nativelog-grpc-forwarder",
+ "plugin_name": "native-log-grpc-forwarder",
"commonfields_pipe_name": "logpipe",
},
},
diff --git a/plugins/forwarder/forwarder_repository.go b/plugins/forwarder/forwarder_repository.go
index 3e3a9b9..6429454 100644
--- a/plugins/forwarder/forwarder_repository.go
+++ b/plugins/forwarder/forwarder_repository.go
@@ -25,11 +25,13 @@ import (
"github.com/apache/skywalking-satellite/plugins/forwarder/grpc/envoymetricsv2"
"github.com/apache/skywalking-satellite/plugins/forwarder/grpc/envoymetricsv3"
grpc_nativecds "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativecds"
+ grpc_nativeebpfprofiling "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativeebpfprofiling"
grpc_nativeevent "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativeevent"
grpc_nativejvm "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativejvm"
grpc_nativelog "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativelog"
grpc_nativemanagement "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativemanagement"
grpc_meter "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativemeter"
+ grpc_nativeprocess "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativeprocess"
grpc_nativeprofile "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativeprofile"
grpc_nativetracing "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativetracing"
kafka_nativelog "github.com/apache/skywalking-satellite/plugins/forwarder/kafka/nativelog"
@@ -52,6 +54,8 @@ func RegisterForwarderPlugins() {
new(grpc_nativecds.Forwarder),
new(grpc_nativeevent.Forwarder),
new(grpc_nativejvm.Forwarder),
+ new(grpc_nativeprocess.Forwarder),
+ new(grpc_nativeebpfprofiling.Forwarder),
new(envoyalsv2.Forwarder),
new(envoyalsv3.Forwarder),
new(envoymetricsv2.Forwarder),
diff --git a/plugins/forwarder/grpc/nativecds/forwarder.go b/plugins/forwarder/grpc/nativecds/forwarder.go
index f8b4b22..28c4b0d 100644
--- a/plugins/forwarder/grpc/nativecds/forwarder.go
+++ b/plugins/forwarder/grpc/nativecds/forwarder.go
@@ -33,7 +33,7 @@ import (
)
const (
- Name = "nativecds-grpc-forwarder"
+ Name = "native-cds-grpc-forwarder"
ShowName = "Native CDS GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativetracing/forwarder.go b/plugins/forwarder/grpc/nativeebpfprofiling/forwarder.go
similarity index 62%
copy from plugins/forwarder/grpc/nativetracing/forwarder.go
copy to plugins/forwarder/grpc/nativeebpfprofiling/forwarder.go
index 1283b32..b9a9852 100644
--- a/plugins/forwarder/grpc/nativetracing/forwarder.go
+++ b/plugins/forwarder/grpc/nativeebpfprofiling/forwarder.go
@@ -15,7 +15,7 @@
// specific language governing permissions and limitations
// under the License.
-package nativetracing
+package nativeebpfprofiling
import (
"context"
@@ -25,24 +25,23 @@ import (
"google.golang.org/grpc"
+ profiling "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/v3"
+ v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
+
"github.com/apache/skywalking-satellite/internal/pkg/config"
"github.com/apache/skywalking-satellite/internal/pkg/log"
"github.com/apache/skywalking-satellite/internal/satellite/event"
- server_grpc "github.com/apache/skywalking-satellite/plugins/server/grpc"
-
- agent "skywalking.apache.org/repo/goapi/collect/language/agent/v3"
- v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
)
const (
- Name = "nativetracing-grpc-forwarder"
- ShowName = "Native Tracing GRPC Forwarder"
+ Name = "native-ebpf-profiling-grpc-forwarder"
+ ShowName = "Native EBPF Profiling GRPC Forwarder"
)
type Forwarder struct {
config.CommonFields
- tracingClient agent.TraceSegmentReportServiceClient
+ profilingClient profiling.EBPFProfilingServiceClient
}
func (f *Forwarder) Name() string {
@@ -54,7 +53,7 @@ func (f *Forwarder) ShowName() string {
}
func (f *Forwarder) Description() string {
- return "This is a synchronization grpc forwarder with the SkyWalking native tracing protocol."
+ return "This is a synchronization grpc forwarder with the SkyWalking native process protocol."
}
func (f *Forwarder) DefaultConfig() string {
@@ -67,35 +66,36 @@ func (f *Forwarder) Prepare(connection interface{}) error {
return fmt.Errorf("the %s only accepts a grpc client, but received a %s",
f.Name(), reflect.TypeOf(connection).String())
}
- f.tracingClient = agent.NewTraceSegmentReportServiceClient(client)
+ f.profilingClient = profiling.NewEBPFProfilingServiceClient(client)
return nil
}
func (f *Forwarder) Forward(batch event.BatchEvents) error {
- stream, err := f.tracingClient.Collect(context.Background())
+ stream, err := f.profilingClient.CollectProfilingData(context.Background())
if err != nil {
- log.Logger.Errorf("open grpc stream error %v", err)
return err
}
for _, e := range batch {
- data, ok := e.GetData().(*v1.SniffData_Segment)
+ data, ok := e.GetData().(*v1.SniffData_EBPFProfilingDataList)
if !ok {
continue
}
- err := stream.SendMsg(server_grpc.NewOriginalData(data.Segment))
- if err != nil {
- log.Logger.Errorf("%s send log data error: %v", f.Name(), err)
- err = closeStream(stream)
+ for _, d := range data.EBPFProfilingDataList.DataList {
+ err := stream.Send(d)
if err != nil {
- log.Logger.Errorf("%s close stream error: %v", f.Name(), err)
+ log.Logger.Errorf("%s send log data error: %v", f.Name(), err)
+ err = closeStream(stream)
+ if err != nil {
+ log.Logger.Errorf("%s close stream error: %v", f.Name(), err)
+ }
+ return err
}
- return err
}
}
return closeStream(stream)
}
-func closeStream(stream agent.TraceSegmentReportService_CollectClient) error {
+func closeStream(stream profiling.EBPFProfilingService_CollectProfilingDataClient) error {
_, err := stream.CloseAndRecv()
if err != nil && err != io.EOF {
return err
@@ -104,13 +104,21 @@ func closeStream(stream agent.TraceSegmentReportService_CollectClient) error {
}
func (f *Forwarder) ForwardType() v1.SniffType {
- return v1.SniffType_TracingType
+ return v1.SniffType_EBPFProfilingType
}
-func (f *Forwarder) SyncForward(_ *v1.SniffData) (*v1.SniffData, error) {
- return nil, fmt.Errorf("unsupport sync forward")
+func (f *Forwarder) SyncForward(e *v1.SniffData) (*v1.SniffData, error) {
+ query := e.GetEBPFProfilingTaskQuery()
+ if query == nil {
+ return nil, fmt.Errorf("unsupport data")
+ }
+ commands, err := f.profilingClient.QueryTasks(context.Background(), query)
+ if err != nil {
+ return nil, err
+ }
+ return &v1.SniffData{Data: &v1.SniffData_Commands{Commands: commands}}, nil
}
func (f *Forwarder) SupportedSyncInvoke() bool {
- return false
+ return true
}
diff --git a/plugins/forwarder/grpc/nativeevent/sync_forwarder.go b/plugins/forwarder/grpc/nativeevent/sync_forwarder.go
index ac2add9..29e89b2 100644
--- a/plugins/forwarder/grpc/nativeevent/sync_forwarder.go
+++ b/plugins/forwarder/grpc/nativeevent/sync_forwarder.go
@@ -34,7 +34,7 @@ import (
)
const (
- Name = "nativeevent-grpc-forwarder"
+ Name = "native-event-grpc-forwarder"
ShowName = "Native Event GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativejvm/sync_forwarder.go b/plugins/forwarder/grpc/nativejvm/sync_forwarder.go
index 6a1aa24..0dd043d 100644
--- a/plugins/forwarder/grpc/nativejvm/sync_forwarder.go
+++ b/plugins/forwarder/grpc/nativejvm/sync_forwarder.go
@@ -32,7 +32,7 @@ import (
)
const (
- Name = "nativejvm-grpc-forwarder"
+ Name = "native-jvm-grpc-forwarder"
ShowName = "Native JVM GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativelog/forwarder.go b/plugins/forwarder/grpc/nativelog/forwarder.go
index 9148a6d..779eb93 100644
--- a/plugins/forwarder/grpc/nativelog/forwarder.go
+++ b/plugins/forwarder/grpc/nativelog/forwarder.go
@@ -35,7 +35,7 @@ import (
)
const (
- Name = "nativelog-grpc-forwarder"
+ Name = "native-log-grpc-forwarder"
ShowName = "Native Log GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativemanagement/forwarder.go b/plugins/forwarder/grpc/nativemanagement/forwarder.go
index 217a11f..212fc91 100644
--- a/plugins/forwarder/grpc/nativemanagement/forwarder.go
+++ b/plugins/forwarder/grpc/nativemanagement/forwarder.go
@@ -32,7 +32,7 @@ import (
)
const (
- Name = "nativemanagement-grpc-forwarder"
+ Name = "native-management-grpc-forwarder"
ShowName = "Native Management GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativemeter/forwarder.go b/plugins/forwarder/grpc/nativemeter/forwarder.go
index 1857df1..9b4511b 100644
--- a/plugins/forwarder/grpc/nativemeter/forwarder.go
+++ b/plugins/forwarder/grpc/nativemeter/forwarder.go
@@ -39,7 +39,7 @@ import (
)
const (
- Name = "nativemeter-grpc-forwarder"
+ Name = "native-meter-grpc-forwarder"
ShowName = "Native Meter GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativecds/forwarder.go b/plugins/forwarder/grpc/nativeprocess/forwarder.go
similarity index 67%
copy from plugins/forwarder/grpc/nativecds/forwarder.go
copy to plugins/forwarder/grpc/nativeprocess/forwarder.go
index f8b4b22..4a6d3c6 100644
--- a/plugins/forwarder/grpc/nativecds/forwarder.go
+++ b/plugins/forwarder/grpc/nativeprocess/forwarder.go
@@ -15,17 +15,16 @@
// specific language governing permissions and limitations
// under the License.
-package nativecds
+package nativeprocess
import (
"context"
"fmt"
"reflect"
- v3 "skywalking.apache.org/repo/goapi/collect/agent/configuration/v3"
-
"google.golang.org/grpc"
+ process "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/process/v3"
v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
"github.com/apache/skywalking-satellite/internal/pkg/config"
@@ -33,14 +32,14 @@ import (
)
const (
- Name = "nativecds-grpc-forwarder"
- ShowName = "Native CDS GRPC Forwarder"
+ Name = "native-process-grpc-forwarder"
+ ShowName = "Native Process GRPC Forwarder"
)
type Forwarder struct {
config.CommonFields
- cdsClient v3.ConfigurationDiscoveryServiceClient
+ processClient process.EBPFProcessServiceClient
}
func (f *Forwarder) Name() string {
@@ -52,7 +51,7 @@ func (f *Forwarder) ShowName() string {
}
func (f *Forwarder) Description() string {
- return "This is a synchronization grpc forwarder with the SkyWalking native Configuration Discovery Service protocol."
+ return "This is a synchronization grpc forwarder with the SkyWalking native process protocol."
}
func (f *Forwarder) DefaultConfig() string {
@@ -65,30 +64,38 @@ func (f *Forwarder) Prepare(connection interface{}) error {
return fmt.Errorf("the %s only accepts a grpc client, but received a %s",
f.Name(), reflect.TypeOf(connection).String())
}
- f.cdsClient = v3.NewConfigurationDiscoveryServiceClient(client)
+ f.processClient = process.NewEBPFProcessServiceClient(client)
return nil
}
func (f *Forwarder) Forward(batch event.BatchEvents) error {
- return fmt.Errorf("the SkyWalking native Configuration Discovery Service protocol " +
- "is not support async forward")
+ for _, e := range batch {
+ data, ok := e.GetData().(*v1.SniffData_EBPFProcessPingPkgList)
+ if !ok {
+ continue
+ }
+ _, err := f.processClient.KeepAlive(context.Background(), data.EBPFProcessPingPkgList)
+ if err != nil {
+ return err
+ }
+ }
+ return nil
}
func (f *Forwarder) ForwardType() v1.SniffType {
- return v1.SniffType_ConfigurationDiscoveryServiceType
+ return v1.SniffType_EBPFProcessType
}
func (f *Forwarder) SyncForward(e *v1.SniffData) (*v1.SniffData, error) {
- query := e.GetConfigurationSyncRequest()
- if query != nil {
- commands, err := f.cdsClient.FetchConfigurations(context.Background(), query)
- if err != nil {
- return nil, err
- }
- return &v1.SniffData{Data: &v1.SniffData_Commands{Commands: commands}}, nil
+ report := e.GetEBPFProcessReportList()
+ if report == nil {
+ return nil, fmt.Errorf("unsupport data")
}
-
- return nil, fmt.Errorf("unsupport data")
+ processes, err := f.processClient.ReportProcesses(context.Background(), report)
+ if err != nil {
+ return nil, err
+ }
+ return &v1.SniffData{Data: &v1.SniffData_EBPFReportProcessDownstream{EBPFReportProcessDownstream: processes}}, nil
}
func (f *Forwarder) SupportedSyncInvoke() bool {
diff --git a/plugins/forwarder/grpc/nativeprofile/forwarder.go b/plugins/forwarder/grpc/nativeprofile/forwarder.go
index f30fe6f..af56c69 100644
--- a/plugins/forwarder/grpc/nativeprofile/forwarder.go
+++ b/plugins/forwarder/grpc/nativeprofile/forwarder.go
@@ -34,7 +34,7 @@ import (
)
const (
- Name = "nativeprofile-grpc-forwarder"
+ Name = "native-profile-grpc-forwarder"
ShowName = "Native Profile GRPC Forwarder"
)
diff --git a/plugins/forwarder/grpc/nativetracing/forwarder.go b/plugins/forwarder/grpc/nativetracing/forwarder.go
index 1283b32..bd87c43 100644
--- a/plugins/forwarder/grpc/nativetracing/forwarder.go
+++ b/plugins/forwarder/grpc/nativetracing/forwarder.go
@@ -35,7 +35,7 @@ import (
)
const (
- Name = "nativetracing-grpc-forwarder"
+ Name = "native-tracing-grpc-forwarder"
ShowName = "Native Tracing GRPC Forwarder"
)
diff --git a/plugins/forwarder/kafka/nativelog/forwarder.go b/plugins/forwarder/kafka/nativelog/forwarder.go
index 06d0046..b13e24e 100644
--- a/plugins/forwarder/kafka/nativelog/forwarder.go
+++ b/plugins/forwarder/kafka/nativelog/forwarder.go
@@ -30,7 +30,7 @@ import (
)
const (
- Name = "nativelog-kafka-forwarder"
+ Name = "native-log-kafka-forwarder"
ShowName = "Native Log Kafka Forwarder"
)
diff --git a/plugins/receiver/grpc/nativecds/receiver.go b/plugins/receiver/grpc/nativecds/receiver.go
index d2cadf4..94b09a5 100644
--- a/plugins/receiver/grpc/nativecds/receiver.go
+++ b/plugins/receiver/grpc/nativecds/receiver.go
@@ -29,7 +29,7 @@ import (
)
const (
- Name = "grpc-nativecds-receiver"
+ Name = "grpc-native-cds-receiver"
ShowName = "GRPC Native CDS Receiver"
)
diff --git a/plugins/receiver/grpc/nativeebpfprofiling/profiling_report_service.go b/plugins/receiver/grpc/nativeebpfprofiling/profiling_report_service.go
new file mode 100644
index 0000000..4b32fac
--- /dev/null
+++ b/plugins/receiver/grpc/nativeebpfprofiling/profiling_report_service.go
@@ -0,0 +1,83 @@
+// Licensed to Apache Software Foundation (ASF) under one or more contributor
+// license agreements. See the NOTICE file distributed with
+// this work for additional information regarding copyright
+// ownership. Apache Software Foundation (ASF) licenses this file to you under
+// the Apache License, Version 2.0 (the "License"); you may
+// not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+package nativeebpfprofiling
+
+import (
+ "context"
+ "io"
+ "time"
+
+ module "github.com/apache/skywalking-satellite/internal/satellite/module/api"
+
+ common "skywalking.apache.org/repo/goapi/collect/common/v3"
+ v3 "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/v3"
+ sniffer "skywalking.apache.org/repo/goapi/satellite/data/v1"
+)
+
+const eventName = "grpc-ebpfebpfprofiling-event"
+
+type ProfilingReportService struct {
+ receiveChannel chan *sniffer.SniffData
+
+ module.SyncInvoker
+ v3.UnimplementedEBPFProfilingServiceServer
+}
+
+func (p *ProfilingReportService) QueryTasks(ctx context.Context, d *v3.EBPFProfilingTaskQuery) (*common.Commands, error) {
+ event := &sniffer.SniffData{
+ Data: &sniffer.SniffData_EBPFProfilingTaskQuery{
+ EBPFProfilingTaskQuery: d,
+ },
+ }
+ data, err := p.SyncInvoker.SyncInvoke(event)
+ if err != nil {
+ return nil, err
+ }
+ return data.GetCommands(), nil
+}
+
+func (p *ProfilingReportService) CollectProfilingData(stream v3.EBPFProfilingService_CollectProfilingDataServer) error {
+ dataList := make([]*v3.EBPFProfilingData, 0)
+ for {
+ snapshot, err := stream.Recv()
+ if err == io.EOF {
+ return p.sendData(dataList, stream)
+ }
+ if err != nil {
+ return err
+ }
+ dataList = append(dataList, snapshot)
+ }
+}
+
+func (p *ProfilingReportService) sendData(dataList []*v3.EBPFProfilingData, stream v3.EBPFProfilingService_CollectProfilingDataServer) error {
+ e := &sniffer.SniffData{
+ Name: eventName,
+ Timestamp: time.Now().UnixNano() / 1e6,
+ Meta: nil,
+ Type: sniffer.SniffType_EBPFProfilingType,
+ Remote: true,
+ Data: &sniffer.SniffData_EBPFProfilingDataList{
+ EBPFProfilingDataList: &sniffer.EBPFProfilingDataList{
+ DataList: dataList,
+ },
+ },
+ }
+ p.receiveChannel <- e
+ return stream.SendAndClose(&common.Commands{})
+}
diff --git a/plugins/receiver/grpc/nativelog/receiver.go b/plugins/receiver/grpc/nativeebpfprofiling/receiver.go
similarity index 70%
copy from plugins/receiver/grpc/nativelog/receiver.go
copy to plugins/receiver/grpc/nativeebpfprofiling/receiver.go
index d293968..9018dd4 100644
--- a/plugins/receiver/grpc/nativelog/receiver.go
+++ b/plugins/receiver/grpc/nativeebpfprofiling/receiver.go
@@ -15,28 +15,28 @@
// specific language governing permissions and limitations
// under the License.
-package nativelog
+package nativeebpfprofiling
import (
- v3 "skywalking.apache.org/repo/goapi/collect/logging/v3"
+ v3 "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/v3"
v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
"github.com/apache/skywalking-satellite/internal/pkg/config"
module "github.com/apache/skywalking-satellite/internal/satellite/module/api"
forwarder "github.com/apache/skywalking-satellite/plugins/forwarder/api"
- forwarder_nativelog "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativelog"
+ forwarder_nativeebpfprofiling "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativeebpfprofiling"
grpcreceiver "github.com/apache/skywalking-satellite/plugins/receiver/grpc"
)
const (
- Name = "grpc-nativelog-receiver"
- ShowName = "GRPC Native Log Receiver"
+ Name = "grpc-native-ebpf-profiling-receiver"
+ ShowName = "GRPC Native EBFP Profiling Receiver"
)
type Receiver struct {
config.CommonFields
grpcreceiver.CommonGRPCReceiverFields
- service *LogReportService // The gRPC request handler for logData.
+ service *ProfilingReportService // The gRPC request handler for profiling data.
}
func (r *Receiver) Name() string {
@@ -48,8 +48,8 @@ func (r *Receiver) ShowName() string {
}
func (r *Receiver) Description() string {
- return "This is a receiver for SkyWalking native logging format, " +
- "which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/logging/Logging.proto."
+ return "This is a receiver for SkyWalking native process format, " +
+ "which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/ebpf/profiling/Process.proto."
}
func (r *Receiver) DefaultConfig() string {
@@ -58,11 +58,12 @@ func (r *Receiver) DefaultConfig() string {
func (r *Receiver) RegisterHandler(server interface{}) {
r.CommonGRPCReceiverFields = *grpcreceiver.InitCommonGRPCReceiverFields(server)
- r.service = &LogReportService{receiveChannel: r.OutputChannel}
- v3.RegisterLogReportServiceServer(r.Server, r.service)
+ r.service = &ProfilingReportService{receiveChannel: r.OutputChannel}
+ v3.RegisterEBPFProfilingServiceServer(r.Server, r.service)
}
-func (r *Receiver) RegisterSyncInvoker(_ module.SyncInvoker) {
+func (r *Receiver) RegisterSyncInvoker(invoker module.SyncInvoker) {
+ r.service.SyncInvoker = invoker
}
func (r *Receiver) Channel() <-chan *v1.SniffData {
@@ -71,6 +72,6 @@ func (r *Receiver) Channel() <-chan *v1.SniffData {
func (r *Receiver) SupportForwarders() []forwarder.Forwarder {
return []forwarder.Forwarder{
- new(forwarder_nativelog.Forwarder),
+ new(forwarder_nativeebpfprofiling.Forwarder),
}
}
diff --git a/plugins/receiver/grpc/nativeebpfprofiling/receiver_test.go b/plugins/receiver/grpc/nativeebpfprofiling/receiver_test.go
new file mode 100644
index 0000000..e790a92
--- /dev/null
+++ b/plugins/receiver/grpc/nativeebpfprofiling/receiver_test.go
@@ -0,0 +1,77 @@
+// Licensed to Apache Software Foundation (ASF) under one or more contributor
+// license agreements. See the NOTICE file distributed with
+// this work for additional information regarding copyright
+// ownership. Apache Software Foundation (ASF) licenses this file to you under
+// the Apache License, Version 2.0 (the "License"); you may
+// not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+package nativeebpfprofiling
+
+import (
+ "context"
+ "testing"
+ "time"
+
+ "google.golang.org/grpc"
+
+ agent "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/v3"
+ v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
+
+ _ "github.com/apache/skywalking-satellite/internal/satellite/test"
+ receiver_grpc "github.com/apache/skywalking-satellite/plugins/receiver/grpc"
+)
+
+func TestReceiver_RegisterHandler(t *testing.T) {
+ receiver_grpc.TestReceiver(new(Receiver), func(t *testing.T, sequence int, conn *grpc.ClientConn, ctx context.Context) string {
+ client := agent.NewEBPFProfilingServiceClient(conn)
+ data := initData()
+ collect, err := client.CollectProfilingData(ctx)
+ if err != nil {
+ t.Fatalf("cannot send data: %v", err)
+ }
+ if err := collect.Send(data); err != nil {
+ t.Fatalf("cannot send the data to the server: %v", err)
+ }
+ if err := collect.CloseSend(); err != nil {
+ t.Fatalf("cannot close the stream: %v", err)
+ }
+ return data.String()
+ }, func(data *v1.SniffData) string {
+ return data.GetEBPFProfilingDataList().DataList[0].String()
+ }, t)
+}
+
+func initData() *agent.EBPFProfilingData {
+ return &agent.EBPFProfilingData{
+ Task: &agent.EBPFProfilingTaskMetadata{
+ TaskId: "test-task",
+ ProcessId: "test-process",
+ ProfilingStartTime: time.Now().Unix() / 1e6,
+ CurrentTime: time.Now().Unix() / 1e6,
+ },
+ Profiling: &agent.EBPFProfilingData_OnCPU{
+ OnCPU: &agent.EBPFOnCPUProfiling{
+ DumpCount: 1,
+ Stacks: []*agent.EBPFProfilingStackMetadata{
+ {
+ StackType: agent.EBPFProfilingStackType_PROCESS_USER_SPACE,
+ StackId: 123,
+ StackSymbols: []string{
+ "stack1", "stack2",
+ },
+ },
+ },
+ },
+ },
+ }
+}
diff --git a/plugins/receiver/grpc/nativeevent/receiver.go b/plugins/receiver/grpc/nativeevent/receiver.go
index 4b591ed..d557ca5 100644
--- a/plugins/receiver/grpc/nativeevent/receiver.go
+++ b/plugins/receiver/grpc/nativeevent/receiver.go
@@ -29,7 +29,7 @@ import (
)
const (
- Name = "grpc-nativeevent-receiver"
+ Name = "grpc-native-event-receiver"
ShowName = "GRPC Native Event Receiver"
)
diff --git a/plugins/receiver/grpc/nativejvm/receiver.go b/plugins/receiver/grpc/nativejvm/receiver.go
index 5c38825..ff4a329 100644
--- a/plugins/receiver/grpc/nativejvm/receiver.go
+++ b/plugins/receiver/grpc/nativejvm/receiver.go
@@ -30,7 +30,7 @@ import (
)
const (
- Name = "grpc-nativejvm-receiver"
+ Name = "grpc-native-jvm-receiver"
ShowName = "GRPC Native JVM Receiver"
)
diff --git a/plugins/receiver/grpc/nativelog/receiver.go b/plugins/receiver/grpc/nativelog/receiver.go
index d293968..17f2869 100644
--- a/plugins/receiver/grpc/nativelog/receiver.go
+++ b/plugins/receiver/grpc/nativelog/receiver.go
@@ -29,7 +29,7 @@ import (
)
const (
- Name = "grpc-nativelog-receiver"
+ Name = "grpc-native-log-receiver"
ShowName = "GRPC Native Log Receiver"
)
diff --git a/plugins/receiver/grpc/nativemanagement/receiver.go b/plugins/receiver/grpc/nativemanagement/receiver.go
index 26debde..371abe0 100644
--- a/plugins/receiver/grpc/nativemanagement/receiver.go
+++ b/plugins/receiver/grpc/nativemanagement/receiver.go
@@ -30,7 +30,7 @@ import (
)
const (
- Name = "grpc-nativemanagement-receiver"
+ Name = "grpc-native-management-receiver"
ShowName = "GRPC Native Management Receiver"
)
diff --git a/plugins/receiver/grpc/nativemeter/receiver.go b/plugins/receiver/grpc/nativemeter/receiver.go
index c515850..620710a 100644
--- a/plugins/receiver/grpc/nativemeter/receiver.go
+++ b/plugins/receiver/grpc/nativemeter/receiver.go
@@ -30,7 +30,7 @@ import (
)
const (
- Name = "grpc-nativemeter-receiver"
+ Name = "grpc-native-meter-receiver"
ShowName = "GRPC Native Meter Receiver"
)
diff --git a/plugins/receiver/grpc/nativeprocess/process_report_service.go b/plugins/receiver/grpc/nativeprocess/process_report_service.go
new file mode 100644
index 0000000..5293a4a
--- /dev/null
+++ b/plugins/receiver/grpc/nativeprocess/process_report_service.go
@@ -0,0 +1,67 @@
+// Licensed to Apache Software Foundation (ASF) under one or more contributor
+// license agreements. See the NOTICE file distributed with
+// this work for additional information regarding copyright
+// ownership. Apache Software Foundation (ASF) licenses this file to you under
+// the Apache License, Version 2.0 (the "License"); you may
+// not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+package nativeprocess
+
+import (
+ "context"
+ "time"
+
+ module "github.com/apache/skywalking-satellite/internal/satellite/module/api"
+
+ common "skywalking.apache.org/repo/goapi/collect/common/v3"
+ v3 "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/process/v3"
+ sniffer "skywalking.apache.org/repo/goapi/satellite/data/v1"
+)
+
+const eventName = "grpc-ebpfprocess-event"
+
+type ProcessReportService struct {
+ receiveChannel chan *sniffer.SniffData
+
+ module.SyncInvoker
+ v3.UnimplementedEBPFProcessServiceServer
+}
+
+func (p *ProcessReportService) ReportProcesses(ctx context.Context, d *v3.EBPFProcessReportList) (*v3.EBPFReportProcessDownstream, error) {
+ event := &sniffer.SniffData{
+ Data: &sniffer.SniffData_EBPFProcessReportList{
+ EBPFProcessReportList: d,
+ },
+ }
+ data, err := p.SyncInvoker.SyncInvoke(event)
+ if err != nil {
+ return nil, err
+ }
+ return data.GetEBPFReportProcessDownstream(), nil
+}
+
+func (p *ProcessReportService) KeepAlive(ctx context.Context, d *v3.EBPFProcessPingPkgList) (*common.Commands, error) {
+ e := &sniffer.SniffData{
+ Name: eventName,
+ Timestamp: time.Now().UnixNano() / 1e6,
+ Meta: nil,
+ Type: sniffer.SniffType_EBPFProcessType,
+ Remote: true,
+ Data: &sniffer.SniffData_EBPFProcessPingPkgList{
+ EBPFProcessPingPkgList: d,
+ },
+ }
+
+ p.receiveChannel <- e
+ return &common.Commands{}, nil
+}
diff --git a/plugins/receiver/grpc/nativelog/receiver.go b/plugins/receiver/grpc/nativeprocess/receiver.go
similarity index 71%
copy from plugins/receiver/grpc/nativelog/receiver.go
copy to plugins/receiver/grpc/nativeprocess/receiver.go
index d293968..8813472 100644
--- a/plugins/receiver/grpc/nativelog/receiver.go
+++ b/plugins/receiver/grpc/nativeprocess/receiver.go
@@ -15,28 +15,28 @@
// specific language governing permissions and limitations
// under the License.
-package nativelog
+package nativeprocess
import (
- v3 "skywalking.apache.org/repo/goapi/collect/logging/v3"
+ v3 "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/process/v3"
v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
"github.com/apache/skywalking-satellite/internal/pkg/config"
module "github.com/apache/skywalking-satellite/internal/satellite/module/api"
forwarder "github.com/apache/skywalking-satellite/plugins/forwarder/api"
- forwarder_nativelog "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativelog"
+ forwarder_nativeprocess "github.com/apache/skywalking-satellite/plugins/forwarder/grpc/nativeprocess"
grpcreceiver "github.com/apache/skywalking-satellite/plugins/receiver/grpc"
)
const (
- Name = "grpc-nativelog-receiver"
- ShowName = "GRPC Native Log Receiver"
+ Name = "grpc-native-process-receiver"
+ ShowName = "GRPC Native Process Receiver"
)
type Receiver struct {
config.CommonFields
grpcreceiver.CommonGRPCReceiverFields
- service *LogReportService // The gRPC request handler for logData.
+ service *ProcessReportService // The gRPC request handler for process data.
}
func (r *Receiver) Name() string {
@@ -48,8 +48,8 @@ func (r *Receiver) ShowName() string {
}
func (r *Receiver) Description() string {
- return "This is a receiver for SkyWalking native logging format, " +
- "which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/logging/Logging.proto."
+ return "This is a receiver for SkyWalking native process format, " +
+ "which is defined at https://github.com/apache/skywalking-data-collect-protocol/blob/master/ebpf/profiling/Process.proto."
}
func (r *Receiver) DefaultConfig() string {
@@ -58,11 +58,12 @@ func (r *Receiver) DefaultConfig() string {
func (r *Receiver) RegisterHandler(server interface{}) {
r.CommonGRPCReceiverFields = *grpcreceiver.InitCommonGRPCReceiverFields(server)
- r.service = &LogReportService{receiveChannel: r.OutputChannel}
- v3.RegisterLogReportServiceServer(r.Server, r.service)
+ r.service = &ProcessReportService{receiveChannel: r.OutputChannel}
+ v3.RegisterEBPFProcessServiceServer(r.Server, r.service)
}
-func (r *Receiver) RegisterSyncInvoker(_ module.SyncInvoker) {
+func (r *Receiver) RegisterSyncInvoker(invoker module.SyncInvoker) {
+ r.service.SyncInvoker = invoker
}
func (r *Receiver) Channel() <-chan *v1.SniffData {
@@ -71,6 +72,6 @@ func (r *Receiver) Channel() <-chan *v1.SniffData {
func (r *Receiver) SupportForwarders() []forwarder.Forwarder {
return []forwarder.Forwarder{
- new(forwarder_nativelog.Forwarder),
+ new(forwarder_nativeprocess.Forwarder),
}
}
diff --git a/plugins/receiver/grpc/nativeprocess/receiver_test.go b/plugins/receiver/grpc/nativeprocess/receiver_test.go
new file mode 100644
index 0000000..1347a78
--- /dev/null
+++ b/plugins/receiver/grpc/nativeprocess/receiver_test.go
@@ -0,0 +1,63 @@
+// Licensed to Apache Software Foundation (ASF) under one or more contributor
+// license agreements. See the NOTICE file distributed with
+// this work for additional information regarding copyright
+// ownership. Apache Software Foundation (ASF) licenses this file to you under
+// the Apache License, Version 2.0 (the "License"); you may
+// not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+package nativeprocess
+
+import (
+ "context"
+ "testing"
+
+ "google.golang.org/grpc"
+
+ agent "skywalking.apache.org/repo/goapi/collect/ebpf/profiling/process/v3"
+ v1 "skywalking.apache.org/repo/goapi/satellite/data/v1"
+
+ _ "github.com/apache/skywalking-satellite/internal/satellite/test"
+ receiver_grpc "github.com/apache/skywalking-satellite/plugins/receiver/grpc"
+)
+
+func TestReceiver_RegisterHandler(t *testing.T) {
+ receiver_grpc.TestReceiver(new(Receiver), func(t *testing.T, sequence int, conn *grpc.ClientConn, ctx context.Context) string {
+ client := agent.NewEBPFProcessServiceClient(conn)
+ data := initData()
+ _, err := client.KeepAlive(ctx, data)
+ if err != nil {
+ t.Fatalf("cannot send data: %v", err)
+ }
+ return data.String()
+ }, func(data *v1.SniffData) string {
+ return data.GetEBPFProcessPingPkgList().String()
+ }, t)
+}
+
+func initData() *agent.EBPFProcessPingPkgList {
+ return &agent.EBPFProcessPingPkgList{
+ Processes: []*agent.EBPFProcessPingPkg{
+ {
+ EntityMetadata: &agent.EBPFProcessEntityMetadata{
+ Layer: "GENERAL",
+ ServiceName: "test-service",
+ InstanceName: "test-instance",
+ ProcessName: "test-process",
+ Labels: []string{
+ "test-label",
+ },
+ },
+ },
+ },
+ }
+}
diff --git a/plugins/receiver/grpc/nativeprofile/receiver.go b/plugins/receiver/grpc/nativeprofile/receiver.go
index 466bf49..2bb84c4 100644
--- a/plugins/receiver/grpc/nativeprofile/receiver.go
+++ b/plugins/receiver/grpc/nativeprofile/receiver.go
@@ -30,7 +30,7 @@ import (
)
const (
- Name = "grpc-nativeprofile-receiver"
+ Name = "grpc-native-profile-receiver"
ShowName = "GRPC Native Profile Receiver"
)
diff --git a/plugins/receiver/grpc/nativetracing/receiver.go b/plugins/receiver/grpc/nativetracing/receiver.go
index 68975ae..2231e2e 100644
--- a/plugins/receiver/grpc/nativetracing/receiver.go
+++ b/plugins/receiver/grpc/nativetracing/receiver.go
@@ -30,7 +30,7 @@ import (
)
const (
- Name = "grpc-nativetracing-receiver"
+ Name = "grpc-native-tracing-receiver"
ShowName = "GRPC Native Tracing Receiver"
)
diff --git a/plugins/receiver/http/nativcelog/receiver.go b/plugins/receiver/http/nativcelog/receiver.go
index cf1d460..aef9b2e 100644
--- a/plugins/receiver/http/nativcelog/receiver.go
+++ b/plugins/receiver/http/nativcelog/receiver.go
@@ -39,7 +39,7 @@ import (
)
const (
- Name = "http-nativelog-receiver"
+ Name = "http-native-log-receiver"
ShowName = "HTTP Native Log Receiver"
eventName = "http-nativelog-event"
success = "success"
diff --git a/plugins/receiver/receiver_repository.go b/plugins/receiver/receiver_repository.go
index 9841ed2..25eaf42 100644
--- a/plugins/receiver/receiver_repository.go
+++ b/plugins/receiver/receiver_repository.go
@@ -27,11 +27,13 @@ import (
"github.com/apache/skywalking-satellite/plugins/receiver/grpc/envoymetricsv2"
"github.com/apache/skywalking-satellite/plugins/receiver/grpc/envoymetricsv3"
grpcnativecds "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativecds"
+ grpcnativeebpfprofiling "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativeebpfprofiling"
grpcnativeevent "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativeevent"
grpcnativejvm "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativejvm"
grpcnavtivelog "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativelog"
grpcnativemanagement "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativemanagement"
grpcnativemeter "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativemeter"
+ grpcnativeprocess "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativeprocess"
grpcnativeprofile "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativeprofile"
grpcnativetracing "github.com/apache/skywalking-satellite/plugins/receiver/grpc/nativetracing"
httpnavtivelog "github.com/apache/skywalking-satellite/plugins/receiver/http/nativcelog"
@@ -51,6 +53,8 @@ func RegisterReceiverPlugins() {
new(grpcnativejvm.Receiver),
new(grpcnativeevent.Receiver),
new(grpcnativemeter.Receiver),
+ new(grpcnativeprocess.Receiver),
+ new(grpcnativeebpfprofiling.Receiver),
new(envoyalsv2.Receiver),
new(envoyalsv3.Receiver),
new(envoymetricsv2.Receiver),
diff --git a/test/e2e/base/base-compose.yml b/test/e2e/base/base-compose.yml
index fe11ee5..ef9a13c 100644
--- a/test/e2e/base/base-compose.yml
+++ b/test/e2e/base/base-compose.yml
@@ -63,7 +63,7 @@ services:
SW_INSTANCE_NAME: provider1
SW_LOGGING_OUTPUT: CONSOLE
healthcheck:
- test: [ "CMD", "sh", "-c", "nc -zn 127.0.0.1 9090"]
+ test: ["CMD", "bash", "-c", "cat < /dev/null > /dev/tcp/127.0.0.1/9090"]
interval: 5s
timeout: 60s
retries: 120
@@ -88,7 +88,7 @@ services:
SW_INSTANCE_NAME: consumer1
SW_LOGGING_OUTPUT: CONSOLE
healthcheck:
- test: [ "CMD", "sh", "-c", "nc -zn 127.0.0.1 9090"]
+ test: ["CMD", "bash", "-c", "cat < /dev/null > /dev/tcp/127.0.0.1/9090"]
interval: 5s
timeout: 60s
retries: 120
diff --git a/test/e2e/base/env b/test/e2e/base/env
index d482588..c2cdabc 100644
--- a/test/e2e/base/env
+++ b/test/e2e/base/env
@@ -13,10 +13,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-SW_AGENT_JAVA_COMMIT=ff5de395a0195d0819f1a96e694fc892b6efeb5d
-SW_OAP_COMMIT=1b85b96570737b75d37819e7c7d538660d7c274e
+SW_AGENT_JAVA_COMMIT=4b24b7d7956240a1968ebfdf313082dac6158a94
+SW_OAP_COMMIT=26d8c36e3a12b6c1cdb687af57b5485fecd4aa0a
SW_UI_COMMIT=1acba5d2467f6d905a6261e999f85464d5432562
SW_KUBERNETES_COMMIT_SHA=1ae3f6c22137a279dce328b202b1f2d59492f9e1
SW_AGENT_JDK_VERSION=8
+SW_ROVER_COMMIT=a58b40e01c670003c211fc9d498a58c70098c364
-SW_CTL_COMMIT=45a5f9807126dc6ea9fe06e17e7aafbe212436d2
+SW_CTL_COMMIT=d2c95c3782f137518b09554331794c10e1457d95
diff --git a/test/e2e/base/scripts/prepare/setup-e2e-shell/install-swctl.sh b/test/e2e/base/scripts/prepare/setup-e2e-shell/install-swctl.sh
index 5893252..f9bcf34 100644
--- a/test/e2e/base/scripts/prepare/setup-e2e-shell/install-swctl.sh
+++ b/test/e2e/base/scripts/prepare/setup-e2e-shell/install-swctl.sh
@@ -22,10 +22,18 @@
BASE_DIR=$1
BIN_DIR=$2
-if ! command -v swctl &> /dev/null; then
+install_swctl() {
mkdir -p $BASE_DIR/swctl && cd $BASE_DIR/swctl
curl -kLo skywalking-cli.tar.gz https://github.com/apache/skywalking-cli/archive/${SW_CTL_COMMIT}.tar.gz
tar -zxf skywalking-cli.tar.gz --strip=1
- utype=$(uname | awk '{print tolower($0)}')
- make $utype && mv bin/swctl-*-$utype-amd64 $BIN_DIR/swctl
-fi
\ No newline at end of file
+ VERSION=${SW_CTL_COMMIT} make install DESTDIR=$BIN_DIR
+}
+
+if ! command -v swctl &> /dev/null; then
+ echo "swctl is not installed"
+ install_swctl
+elif ! swctl --version | grep -q "${SW_CTL_COMMIT}"; then
+ # Check if the installed version is correct
+ echo "swctl is already installed, but version is not ${SW_CTL_COMMIT}, will re-install it"
+ install_swctl
+fi
diff --git a/test/e2e/case/istio/als/e2e.yaml b/test/e2e/case/istio/als/e2e.yaml
index f5559ce..725ed6e 100644
--- a/test/e2e/case/istio/als/e2e.yaml
+++ b/test/e2e/case/istio/als/e2e.yaml
@@ -170,15 +170,11 @@ verify:
# service endpoint metrics: e2e::productpage GET:/productpage
- query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=endpoint_cpm --endpoint-name=GET:/productpage --service-name=e2e::productpage |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- - query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=endpoint_avg --endpoint-name=GET:/productpage --service-name=e2e::productpage |yq e 'to_entries' -
- expected: expected/metrics-has-value.yml
- query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=endpoint_sla --endpoint-name=GET:/productpage --service-name=e2e::productpage |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
# service endpoint metrics: e2e::reviews GET:/reviews/0
- query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=endpoint_cpm --endpoint-name=GET:/reviews/0 --service-name=e2e::reviews |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- - query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=endpoint_avg --endpoint-name=GET:/reviews/0 --service-name=e2e::reviews |yq e 'to_entries' -
- expected: expected/metrics-has-value.yml
- query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=endpoint_sla --endpoint-name=GET:/reviews/0 --service-name=e2e::reviews |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
diff --git a/test/e2e/case/istio/als/expected/service-instance.yml b/test/e2e/case/istio/als/expected/service-instance.yml
index 658cdbd..d862389 100644
--- a/test/e2e/case/istio/als/expected/service-instance.yml
+++ b/test/e2e/case/istio/als/expected/service-instance.yml
@@ -19,4 +19,5 @@
attributes: []
language: UNKNOWN
instanceuuid: {{ notEmpty .instanceuuid }}
+ layer: MESH
{{- end }}
diff --git a/test/e2e/case/istio/als/expected/service.yml b/test/e2e/case/istio/als/expected/service.yml
index ba6d14b..35aa6d7 100644
--- a/test/e2e/case/istio/als/expected/service.yml
+++ b/test/e2e/case/istio/als/expected/service.yml
@@ -14,22 +14,46 @@
# limitations under the License.
{{- contains . }}
-- id: {{ b64enc "e2e::istio-ingressgateway" }}.1
- name: e2e::istio-ingressgateway
- group: ""
+- id: {{ b64enc "e2e::details" }}.1
+ name: e2e::details
+ group: "e2e"
+ shortname: details
+ layers:
+ - MESH
+ normal: true
- id: {{ b64enc "e2e::reviews" }}.1
name: e2e::reviews
- group: ""
+ group: "e2e"
+ shortname: reviews
+ layers:
+ - MESH
+ normal: true
+- id: {{ b64enc "e2e::istio-ingressgateway" }}.1
+ name: e2e::istio-ingressgateway
+ group: "e2e"
+ shortname: istio-ingressgateway
+ layers:
+ - MESH
+ normal: true
- id: {{ b64enc "e2e::ratings" }}.1
name: e2e::ratings
- group: ""
+ group: "e2e"
+ shortname: ratings
+ layers:
+ - MESH
+ normal: true
- id: {{ b64enc "e2e::productpage" }}.1
name: e2e::productpage
- group: ""
-- id: {{ b64enc "e2e::details" }}.1
- name: e2e::details
- group: ""
+ group: "e2e"
+ shortname: productpage
+ layers:
+ - MESH
+ normal: true
- id: {{ b64enc "e2e::mongodb" }}.1
name: e2e::mongodb
- group: ""
+ group: "e2e"
+ shortname: mongodb
+ layers:
+ - MESH
+ normal: true
{{- end }}
diff --git a/test/e2e/case/istio/metrics/e2e.yaml b/test/e2e/case/istio/metrics/e2e.yaml
index c6f1fcc..4c8b512 100644
--- a/test/e2e/case/istio/metrics/e2e.yaml
+++ b/test/e2e/case/istio/metrics/e2e.yaml
@@ -113,104 +113,104 @@ verify:
- query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql service ls
expected: expected/service.yml
# service instance list
- - query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage
+ - query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage
expected: expected/service-instance.yml
- - query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway
+ - query: swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway
expected: expected/service-instance.yml
- # service instance metrics: istio-dp::e2e::productpage
+ # service instance metrics: e2e::productpage
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_used --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_used --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_max_used --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_max_used --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated_max --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated_max --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size_max --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size_max --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads_max --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads_max --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- # service instance metrics: istio-dp::e2e::istio-ingressgateway
+ # service instance metrics: e2e::istio-ingressgateway
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_used --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_used --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_max_used --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_heap_memory_max_used --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated_max --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_allocated_max --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size_max --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_memory_physical_size_max --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads_max --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics linear --name=envoy_worker_threads_max --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
) |yq e 'to_entries' -
expected: expected/metrics-has-value.yml
- # service instance labeled metrics: istio-dp::e2e::productpage, label: e2e::details
+ # service instance labeled metrics: e2e::productpage, label: e2e::details
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics multiple-linear --labels=e2e::details --name=envoy_cluster_membership_healthy --service-name=istio-dp::e2e::productpage --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::productpage | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics multiple-linear --labels=e2e::details --name=envoy_cluster_membership_healthy --service-name=e2e::productpage --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::productpage | yq e '.[0].name' -
)|yq e 'to_entries' -|yq e '.[].value|to_entries' -
expected: expected/metrics-has-value.yml
- # service instance labeled metrics: istio-dp::e2e::productpage, label: e2e::details
+ # service instance labeled metrics: e2e::productpage, label: e2e::details
- query: |
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics multiple-linear --labels=e2e::details --name=envoy_cluster_membership_healthy --service-name=istio-dp::e2e::istio-ingressgateway --instance-name=$( \
- swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=istio-dp::e2e::istio-ingressgateway | yq e '.[0].name' -
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql metrics multiple-linear --labels=e2e::details --name=envoy_cluster_membership_healthy --service-name=e2e::istio-ingressgateway --instance-name=$( \
+ swctl --display yaml --base-url=http://${service_skywalking_ui_host}:${service_skywalking_ui_80}/graphql instance list --service-name=e2e::istio-ingressgateway | yq e '.[0].name' -
)|yq e 'to_entries' -|yq e '.[].value|to_entries' -
expected: expected/metrics-has-value.yml
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/istio/metrics/expected/service-instance.yml
index 658cdbd..b8e3c0f 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/istio/metrics/expected/service-instance.yml
@@ -19,4 +19,5 @@
attributes: []
language: UNKNOWN
instanceuuid: {{ notEmpty .instanceuuid }}
+ layer: MESH_DP
{{- end }}
diff --git a/test/e2e/case/istio/metrics/expected/service.yml b/test/e2e/case/istio/metrics/expected/service.yml
index 47194f3..b77644d 100644
--- a/test/e2e/case/istio/metrics/expected/service.yml
+++ b/test/e2e/case/istio/metrics/expected/service.yml
@@ -13,23 +13,47 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-{{- contains . }}
-- id: {{ b64enc "istio-dp::e2e::istio-egressgateway" }}.1
- name: istio-dp::e2e::istio-egressgateway
- group: ""
-- id: {{ b64enc "istio-dp::e2e::istio-ingressgateway" }}.1
- name: istio-dp::e2e::istio-ingressgateway
- group: ""
-- id: {{ b64enc "istio-dp::e2e::reviews" }}.1
- name: istio-dp::e2e::reviews
- group: ""
-- id: {{ b64enc "istio-dp::e2e::productpage" }}.1
- name: istio-dp::e2e::productpage
- group: ""
-- id: {{ b64enc "istio-dp::e2e::details" }}.1
- name: istio-dp::e2e::details
- group: ""
-- id: {{ b64enc "istio-dp::e2e::ratings" }}.1
- name: istio-dp::e2e::ratings
- group: ""
-{{- end }}
+ {{- contains . }}
+- id: {{ b64enc "e2e::istio-egressgateway" }}.1
+ name: e2e::istio-egressgateway
+ group: "e2e"
+ shortname: istio-egressgateway
+ normal: true
+ layers:
+ - MESH_DP
+- id: {{ b64enc "e2e::istio-ingressgateway" }}.1
+ name: e2e::istio-ingressgateway
+ group: "e2e"
+ shortname: istio-ingressgateway
+ normal: true
+ layers:
+ - MESH_DP
+- id: {{ b64enc "e2e::reviews" }}.1
+ name: e2e::reviews
+ group: "e2e"
+ shortname: reviews
+ normal: true
+ layers:
+ - MESH_DP
+- id: {{ b64enc "e2e::productpage" }}.1
+ name: e2e::productpage
+ group: "e2e"
+ shortname: productpage
+ normal: true
+ layers:
+ - MESH_DP
+- id: {{ b64enc "e2e::details" }}.1
+ name: e2e::details
+ group: "e2e"
+ shortname: details
+ normal: true
+ layers:
+ - MESH_DP
+- id: {{ b64enc "e2e::ratings" }}.1
+ name: e2e::ratings
+ group: "e2e"
+ shortname: ratings
+ normal: true
+ layers:
+ - MESH_DP
+ {{- end }}
diff --git a/test/e2e/case/native-ebpf/Dockerfile.sqrt b/test/e2e/case/native-ebpf/Dockerfile.sqrt
new file mode 100644
index 0000000..432e696
--- /dev/null
+++ b/test/e2e/case/native-ebpf/Dockerfile.sqrt
@@ -0,0 +1,23 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+FROM golang:1.17
+
+WORKDIR /
+COPY sqrt.go /sqrt.go
+RUN go build -o sqrt sqrt.go
+
+CMD ["/sqrt"]
\ No newline at end of file
diff --git a/test/e2e/case/native-ebpf/docker-compose.yml b/test/e2e/case/native-ebpf/docker-compose.yml
new file mode 100644
index 0000000..598b586
--- /dev/null
+++ b/test/e2e/case/native-ebpf/docker-compose.yml
@@ -0,0 +1,77 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+version: '2.1'
+
+services:
+ oap:
+ extends:
+ file: ../../base/base-compose.yml
+ service: oap
+ ports:
+ - 12800:12800
+
+ satellite:
+ extends:
+ file: ../../base/base-compose.yml
+ service: satellite
+ environment:
+ SATELLITE_GRPC_CLIENT_FINDER: static
+ SATELLITE_GRPC_CLIENT: oap:11800
+ SATELLITE_LOGPIPE_SENDER_MIN_FLUSH_EVENTS: 1
+ SATELLITE_GRPC_ACCEPT_LIMIT_CPU_UTILIZATION: 100
+ ports:
+ - 11800
+ depends_on:
+ oap:
+ condition: service_healthy
+
+ rover:
+ image: "ghcr.io/apache/skywalking-rover/skywalking-rover:${SW_ROVER_COMMIT}"
+ networks:
+ - e2e
+ privileged: true
+ pid: host
+ environment:
+ ROVER_HOST_MAPPING: /host
+ ROVER_BACKEND_ADDR: satellite:11800
+ ROVER_PROCESS_DISCOVERY_HEARTBEAT_PERIOD: 2s
+ ROVER_PROCESS_DISCOVERY_VM_ACTIVE: "true"
+ ROVER_PROCESS_DISCOVERY_SCAN_MODE: REGEX
+ ROVER_PROCESS_DISCOVERY_REGEX_SCANNER_MATCH_CMD: sqrt
+ ROVER_PROCESS_DISCOVERY_REGEX_SCANNER_LAYER: OS_LINUX
+ ROVER_PROCESS_DISCOVERY_REGEX_SCANNER_SERVICE_NAME: sqrt
+ ROVER_PROCESS_DISCOVERY_REGEX_SCANNER_INSTANCE_NAME: test-instance
+ ROVER_PROCESS_DISCOVERY_REGEX_SCANNER_PROCESS_NAME: "{{.Process.ExeName}}"
+ ROVER_PROCESS_DISCOVERY_REGEX_SCANNER_LABELS: e2e-label1,e2e-label2
+ ROVER_PROFILING_ACTIVE: "true"
+ ROVER_PROFILING_CHECK_INTERVAL: 2s
+ ROVER_PROFILING_FLUSH_INTERVAL: 5s
+ ROVER_PROFILING_TASK_ON_CPU_DUMP_PERIOD: 9ms
+ volumes:
+ - /:/host
+ depends_on:
+ satellite:
+ condition: service_healthy
+
+ sqrt_go:
+ build:
+ context: .
+ dockerfile: Dockerfile.sqrt
+ networks:
+ - e2e
+
+networks:
+ e2e:
\ No newline at end of file
diff --git a/test/e2e/case/native-ebpf/e2e.yaml b/test/e2e/case/native-ebpf/e2e.yaml
new file mode 100644
index 0000000..6b7ede2
--- /dev/null
+++ b/test/e2e/case/native-ebpf/e2e.yaml
@@ -0,0 +1,63 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+setup:
+ env: compose
+ file: docker-compose.yml
+ timeout: 20m
+ init-system-environment: ../../base/env
+ steps:
+ - name: set PATH
+ command: export PATH=/tmp/skywalking-infra-e2e/bin:$PATH
+ - name: install yq
+ command: bash test/e2e/base/scripts/prepare/setup-e2e-shell/install.sh yq
+ - name: install swctl
+ command: bash test/e2e/base/scripts/prepare/setup-e2e-shell/install.sh swctl
+
+verify:
+ # verify with retry strategy
+ retry:
+ # max retry count
+ count: 20
+ # the interval between two retries, in millisecond.
+ interval: 10s
+ cases:
+ - query: swctl --display yaml service ls
+ expected: expected/service.yml
+ - query: swctl --display yaml instance ls --service-name sqrt
+ expected: expected/instance.yml
+ - query: swctl --display yaml process ls --service-name sqrt --instance-name test-instance
+ expected: expected/process.yml
+ - query: swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf create prepare --service-name sqrt
+ expected: expected/profiling-create-prepare.yml
+ - query: swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml process estimate scale --service-name sqrt --labels e2e-label1,e2e-label2
+ expected: expected/process-estimate-scale.yml
+ - query: |
+ swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf create fixed --service-name sqrt --labels e2e-label1,e2e-label2 --duration 1m
+ expected: expected/profiling-create.yml
+ - query: swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf list --service-name sqrt
+ expected: expected/profiling-task-list.yml
+ - query: |
+ swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf schedules --task-id=$( \
+ swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf list --service-name sqrt |yq e '.[0].taskid' -
+ )
+ expected: expected/profiling-schedule-list.yml
+ - query: |
+ taskid=$(swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf list --service-name sqrt |yq e '.[0].taskid' -)
+ scheduleid=$(swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf schedules --task-id=$taskid |yq e '.[0].scheduleid' -);
+ start=$(swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf schedules --task-id=$taskid | yq e '.[0].starttime' -)
+ end=$(swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf schedules --task-id=$taskid | yq e '.[0].endtime' -)
+ swctl --base-url=http://${oap_host}:${oap_12800}/graphql --display yaml profiling ebpf analysis --schedule-id=$scheduleid --time-ranges=$start-$end
+ expected: profiling-analysis.yml
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/instance.yml
similarity index 89%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/instance.yml
index 658cdbd..b5c287a 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/instance.yml
@@ -14,9 +14,10 @@
# limitations under the License.
{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
+- id: {{ b64enc "sqrt" }}.1_{{ b64enc "test-instance" }}
+ name: test-instance
attributes: []
language: UNKNOWN
instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+ layer: OS_LINUX
+{{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/process-estimate-scale.yml
similarity index 82%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/process-estimate-scale.yml
index 658cdbd..a4bfca0 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/process-estimate-scale.yml
@@ -13,10 +13,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+1
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/process.yml
similarity index 60%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/process.yml
index 658cdbd..31fac87 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/process.yml
@@ -15,8 +15,26 @@
{{- contains . }}
- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+ name: sqrt
+ serviceid: {{ b64enc "sqrt" }}.1
+ servicename: sqrt
+ instanceid: {{ b64enc "sqrt" }}.1_{{ b64enc "test-instance" }}
+ instancename: test-instance
+ layer: OS_LINUX
+ agentid: {{ notEmpty .agentid }}
+ detecttype: VM
+ attributes:
+ {{- contains .attributes }}
+ - name: host_ip
+ value: {{ notEmpty .value }}
+ - name: pid
+ value: {{ notEmpty .value }}
+ - name: command_line
+ value: /sqrt
+ {{- end }}
+ labels:
+ {{- contains .labels }}
+ - e2e-label1
+ - e2e-label2
+ {{- end }}
+{{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/profiling-create-prepare.yml
similarity index 82%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/profiling-create-prepare.yml
index 658cdbd..b1226a3 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/profiling-create-prepare.yml
@@ -13,10 +13,9 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+couldprofiling: true
+processlabels:
+ {{- contains .processlabels }}
+ - e2e-label1
+ - e2e-label2
+ {{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/profiling-create.yml
similarity index 82%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/profiling-create.yml
index 658cdbd..176b195 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/profiling-create.yml
@@ -13,10 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+status: true
+errorreason: null
+id: {{ notEmpty .id }}
\ No newline at end of file
diff --git a/test/e2e/case/native-protocols/expected/event-list.yml b/test/e2e/case/native-ebpf/expected/profiling-schedule-list.yml
similarity index 53%
copy from test/e2e/case/native-protocols/expected/event-list.yml
copy to test/e2e/case/native-ebpf/expected/profiling-schedule-list.yml
index e5a19bf..e19b699 100644
--- a/test/e2e/case/native-protocols/expected/event-list.yml
+++ b/test/e2e/case/native-ebpf/expected/profiling-schedule-list.yml
@@ -13,22 +13,33 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-events:
-{{- contains .events }}
-- uuid: {{ notEmpty .uuid }}
- source:
- service: e2e-service-provider
- serviceinstance: provider1
- endpoint: ""
- name: Start
- type: Normal
- message: Start Java Application
- parameters:
- {{- contains .parameters }}
- - key: OPTS
- value: {{ notEmpty .value }}
- {{- end }}
+{{- contains . }}
+- scheduleid: {{ notEmpty .scheduleid }}
+ taskid: {{ notEmpty .taskid }}
+ process:
+ id: {{ notEmpty .process.id }}
+ name: sqrt
+ serviceid: {{ b64enc "sqrt" }}.1
+ servicename: sqrt
+ instanceid: {{ b64enc "sqrt" }}.1_{{ b64enc "test-instance" }}
+ instancename: test-instance
+ layer: OS_LINUX
+ agentid: {{ notEmpty .process.agentid }}
+ detecttype: VM
+ attributes:
+ {{- contains .process.attributes }}
+ - name: host_ip
+ value: {{ notEmpty .value }}
+ - name: pid
+ value: {{ notEmpty .value }}
+ - name: command_line
+ value: /sqrt
+ {{- end }}
+ labels:
+ {{- contains .process.labels }}
+ - e2e-label1
+ - e2e-label2
+ {{- end }}
starttime: {{ gt .starttime 0 }}
endtime: {{ gt .endtime 0 }}
-{{- end }}
-total: {{ gt .total 0 }}
\ No newline at end of file
+{{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/profiling-task-list.yml
similarity index 69%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/profiling-task-list.yml
index 658cdbd..f561c46 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/profiling-task-list.yml
@@ -14,9 +14,17 @@
# limitations under the License.
{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+- taskid: {{ notEmpty .taskid }}
+ serviceid: {{ b64enc "sqrt" }}.1
+ servicename: sqrt
+ processlabels:
+ {{- contains .processlabels }}
+ - e2e-label1
+ - e2e-label2
+ {{- end }}
+ taskstarttime: {{ gt .taskstarttime 0 }}
+ triggertype: FIXED_TIME
+ fixedtriggerduration: 60
+ targettype: ON_CPU
+ createtime: {{ gt .createtime 0 }}
+{{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/expected/service.yml
similarity index 84%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/expected/service.yml
index 658cdbd..4c0ee2b 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/expected/service.yml
@@ -14,9 +14,11 @@
# limitations under the License.
{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
-{{- end }}
+- id: {{ b64enc "sqrt" }}.1
+ name: sqrt
+ group: ""
+ shortname: sqrt
+ layers:
+ - OS_LINUX
+ normal: true
+{{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/istio/metrics/expected/service-instance.yml b/test/e2e/case/native-ebpf/profiling-analysis.yml
similarity index 75%
copy from test/e2e/case/istio/metrics/expected/service-instance.yml
copy to test/e2e/case/native-ebpf/profiling-analysis.yml
index 658cdbd..c8fe9d3 100644
--- a/test/e2e/case/istio/metrics/expected/service-instance.yml
+++ b/test/e2e/case/native-ebpf/profiling-analysis.yml
@@ -13,10 +13,15 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-{{- contains . }}
-- id: {{ notEmpty .id }}
- name: {{ notEmpty .name }}
- attributes: []
- language: UNKNOWN
- instanceuuid: {{ notEmpty .instanceuuid }}
+tip: null
+trees:
+{{- contains .trees }}
+- elements:
+ {{- contains .elements }}
+ - id: "{{ notEmpty .id }}"
+ parentid: "{{ notEmpty .parentid }}"
+ symbol: "main.sqrtGolang"
+ stacktype: USER_SPACE
+ dumpcount: {{ gt .dumpcount 0 }}
{{- end }}
+{{- end }}
\ No newline at end of file
diff --git a/test/e2e/case/native-ebpf/sqrt.go b/test/e2e/case/native-ebpf/sqrt.go
new file mode 100644
index 0000000..1fc3d01
--- /dev/null
+++ b/test/e2e/case/native-ebpf/sqrt.go
@@ -0,0 +1,32 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package main
+
+import (
+ "math"
+)
+
+//go:noinline
+func sqrtGolang() {
+ for {
+ math.Sqrt(10000)
+ }
+}
+
+func main() {
+ sqrtGolang()
+}
diff --git a/test/e2e/case/native-protocols/e2e.yaml b/test/e2e/case/native-protocols/e2e.yaml
index 2eb1d07..f048af6 100644
--- a/test/e2e/case/native-protocols/e2e.yaml
+++ b/test/e2e/case/native-protocols/e2e.yaml
@@ -84,29 +84,29 @@ verify:
expected: expected/logs-list.yml
# native profile: create task
- - query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile create --service-name e2e-service-provider --endpoint-name POST:/info --start-time=$((($(date +%s)+5)*1000)) --duration=1 --min-duration-threshold=0 --dump-period=10 --max-sampling-count=9
+ - query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace create --service-name e2e-service-provider --endpoint-name POST:/info --start-time=$((($(date +%s)+5)*1000)) --duration=1 --min-duration-threshold=0 --dump-period=10 --max-sampling-count=9
expected: expected/profile-create.yml
# native profile: sleep to wait agent notices and query profile list
- - query: sleep 10 && swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile list --service-name e2e-service-provider --endpoint-name POST:/info
+ - query: sleep 10 && swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace list --service-name e2e-service-provider --endpoint-name POST:/info
expected: expected/profile-list.yml
# native profile: sleep to wait segment report and query profiled segment list
- query: |
curl -X POST http://${consumer_host}:${consumer_9090}/info > /dev/null;
sleep 5;
- swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile segment-list --task-id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile list --service-name e2e-service-provider --endpoint-name POST:/info|yq e '.[0].id' -)
+ swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace segment-list --task-id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace list --service-name e2e-service-provider --endpoint-name POST:/info|yq e '.[0].id' -)
expected: expected/profile-segment-list.yml
# native profile: query profiled segment
- query: |
- task_id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile list --service-name e2e-service-provider --endpoint-name POST:/info|yq e '.[0].id' -)
- segment_id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile segment-list --task-id=$task_id | yq e '.[0].segmentid' -)
- swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile profiled-segment --segment-id=$segment_id
+ task_id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace list --service-name e2e-service-provider --endpoint-name POST:/info|yq e '.[0].id' -)
+ segment_id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace segment-list --task-id=$task_id | yq e '.[0].segmentid' -)
+ swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace profiled-segment --segment-id=$segment_id
expected: expected/profile-segment-detail.yml
# native profile: query profiled segment
- query: |
- segmentid=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile segment-list --task-id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile list --service-name e2e-service-provider --endpoint-name POST:/info|yq e '.[0].id' -) |yq e '.[0].segmentid' -);
- start=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile profiled-segment --segment-id=$segmentid|yq e '.spans.[0].starttime' -);
- end=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile profiled-segment --segment-id=$segmentid|yq e '.spans.[0].endtime' -);
- swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profile profiled-analyze --segment-id=$segmentid --time-ranges=$(echo $start"-"$end)
+ segmentid=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace segment-list --task-id=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace list --service-name e2e-service-provider --endpoint-name POST:/info|yq e '.[0].id' -) |yq e '.[0].segmentid' -);
+ start=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace profiled-segment --segment-id=$segmentid|yq e '.spans.[0].starttime' -);
+ end=$(swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace profiled-segment --segment-id=$segmentid|yq e '.spans.[0].endtime' -);
+ swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql profiling trace analysis --segment-id=$segmentid --time-ranges=$(echo $start"-"$end)
expected: expected/profile-segment-analyze.yml
# native CDS: using etcdctl to update trace span limit, "/users" should have more than one span because it need DB save
diff --git a/test/e2e/case/native-protocols/expected/event-list.yml b/test/e2e/case/native-protocols/expected/event-list.yml
index e5a19bf..5511416 100644
--- a/test/e2e/case/native-protocols/expected/event-list.yml
+++ b/test/e2e/case/native-protocols/expected/event-list.yml
@@ -30,5 +30,6 @@ events:
{{- end }}
starttime: {{ gt .starttime 0 }}
endtime: {{ gt .endtime 0 }}
+ layer: GENERAL
{{- end }}
total: {{ gt .total 0 }}
\ No newline at end of file
diff --git a/test/e2e/case/native-protocols/expected/logs-list.yml b/test/e2e/case/native-protocols/expected/logs-list.yml
index cb0aa04..e3cf55a 100644
--- a/test/e2e/case/native-protocols/expected/logs-list.yml
+++ b/test/e2e/case/native-protocols/expected/logs-list.yml
@@ -19,8 +19,8 @@ logs:
serviceid: {{ b64enc "e2e-service-provider" }}.1
serviceinstancename: provider1
serviceinstanceid: {{ b64enc "e2e-service-provider" }}.1_{{ b64enc "provider1" }}
- endpointname: null
- endpointid: null
+ endpointname: POST:/info
+ endpointid: {{ b64enc "e2e-service-provider" }}.1_{{ b64enc "POST:/info" }}
traceid: {{ notEmpty .traceid }}
timestamp: {{ gt .timestamp 0 }}
contenttype: TEXT
diff --git a/test/e2e/case/native-protocols/expected/service-instance.yml b/test/e2e/case/native-protocols/expected/service-instance.yml
index 652b013..0f1fb16 100644
--- a/test/e2e/case/native-protocols/expected/service-instance.yml
+++ b/test/e2e/case/native-protocols/expected/service-instance.yml
@@ -25,7 +25,7 @@
- name: hostname
value: {{ notEmpty .value }}
- name: Process No.
- value: "1"
+ value: {{ notEmpty .value }}
- name: Start Time
value: {{ notEmpty .value }}
- name: JVM Arguments
@@ -37,4 +37,5 @@
{{- end}}
language: JAVA
instanceuuid: {{ b64enc "e2e-service-provider" }}.1_{{ b64enc "provider1" }}
+ layer: GENERAL
{{- end}}
\ No newline at end of file
diff --git a/test/e2e/case/native-protocols/expected/service.yml b/test/e2e/case/native-protocols/expected/service.yml
index 66502d0..b9bd7c5 100644
--- a/test/e2e/case/native-protocols/expected/service.yml
+++ b/test/e2e/case/native-protocols/expected/service.yml
@@ -16,8 +16,16 @@
{{- contains . }}
- id: {{ b64enc "e2e-service-provider" }}.1
name: e2e-service-provider
+ shortname: e2e-service-provider
group: ""
+ layers:
+ - GENERAL
+ normal: true
- id: {{ b64enc "e2e-service-consumer" }}.1
name: e2e-service-consumer
+ shortname: e2e-service-consumer
group: ""
+ layers:
+ - GENERAL
+ normal: true
{{- end }}
\ No newline at end of file