You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by ke...@apache.org on 2021/11/22 10:06:47 UTC

[skywalking-showcase] branch main updated: Add alarm feature to demo, fix control plane metrics not work (#12)

This is an automated email from the ASF dual-hosted git repository.

kezhenxu94 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/skywalking-showcase.git


The following commit(s) were added to refs/heads/main by this push:
     new e3f35b5  Add alarm feature to demo, fix control plane metrics not work (#12)
e3f35b5 is described below

commit e3f35b51f4581303d5c5a62160f3c419ba2c3f52
Author: kezhenxu94 <ke...@apache.org>
AuthorDate: Mon Nov 22 18:06:41 2021 +0800

    Add alarm feature to demo, fix control plane metrics not work (#12)
---
 Makefile.in                                               |  4 ++--
 deploy/platform/kubernetes/feature-cluster/resources.yaml | 15 +++++++++++----
 .../kubernetes/feature-single-node/resources.yaml         | 12 ++++++++++--
 3 files changed, 23 insertions(+), 8 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index dec44b9..682e14d 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -26,8 +26,8 @@ TAG ?= $(shell git rev-parse --short HEAD)
 
 ES_IMAGE ?= docker.elastic.co/elasticsearch/elasticsearch-oss:7.10.0
 
-SW_OAP_IMAGE ?= ghcr.io/apache/skywalking/oap:b63008c61e1fcb1d69b25a8be7ce99f1d987a175
-SW_ROCKET_BOT_IMAGE ?= ghcr.io/apache/skywalking/ui:b63008c61e1fcb1d69b25a8be7ce99f1d987a175
+SW_OAP_IMAGE ?= ghcr.io/apache/skywalking/oap:b01ee4c983a603476f12a1968d144a983849c8bb
+SW_ROCKET_BOT_IMAGE ?= ghcr.io/apache/skywalking/ui:b01ee4c983a603476f12a1968d144a983849c8bb
 SW_CLI_IMAGE ?= ghcr.io/apache/skywalking-cli/skywalking-cli:8c5725f2c4c47de6091748c1b4747f0d6047ad8e
 SW_EVENT_EXPORTER_IMAGE ?= ghcr.io/apache/skywalking-kubernetes-event-exporter/skywalking-kubernetes-event-exporter:8a012a3f968cb139f817189afb9b3748841bba22
 
diff --git a/deploy/platform/kubernetes/feature-cluster/resources.yaml b/deploy/platform/kubernetes/feature-cluster/resources.yaml
index d6dc7a0..44441f9 100644
--- a/deploy/platform/kubernetes/feature-cluster/resources.yaml
+++ b/deploy/platform/kubernetes/feature-cluster/resources.yaml
@@ -33,6 +33,15 @@ apiVersion: v1
 data:
   metadata-service-mapping.yaml: |
     serviceName: agentless::${LABELS."service.istio.io/canonical-name",LABELS."app.kubernetes.io/name",LABELS.app}
+    serviceInstanceName: ${NAME,NAME} # Just to skip the "envsubst" replacement
+  alarm-settings.yml: |
+    rules:
+      service_resp_time_rule:
+        metrics-name: service_resp_time
+        threshold: 20 # 20ms is just for demo
+        op: ">"
+        period: 5
+        count: 1
 kind: ConfigMap
 metadata:
   name: oap-static-config
@@ -151,8 +160,7 @@ spec:
               value: prometheus
           volumeMounts:
             - name: config-volume
-              mountPath: /skywalking/config/metadata-service-mapping.yaml
-              subPath: metadata-service-mapping.yaml
+              mountPath: /skywalking/ext-config
       volumes:
         - name: config-volume
           configMap:
@@ -236,8 +244,7 @@ spec:
               value: k8s-configmap
           volumeMounts:
             - name: config-volume
-              mountPath: /skywalking/config/metadata-service-mapping.yaml
-              subPath: metadata-service-mapping.yaml
+              mountPath: /skywalking/ext-config
       volumes:
         - name: config-volume
           configMap:
diff --git a/deploy/platform/kubernetes/feature-single-node/resources.yaml b/deploy/platform/kubernetes/feature-single-node/resources.yaml
index 49ff0c3..05ba50f 100644
--- a/deploy/platform/kubernetes/feature-single-node/resources.yaml
+++ b/deploy/platform/kubernetes/feature-single-node/resources.yaml
@@ -33,6 +33,15 @@ apiVersion: v1
 data:
   metadata-service-mapping.yaml: |
     serviceName: agentless::${LABELS."service.istio.io/canonical-name",LABELS."app.kubernetes.io/name",LABELS.app}
+    serviceInstanceName: ${NAME,NAME} # Just to skip the "envsubst" replacement
+  alarm-settings.yml: |
+    rules:
+      service_resp_time_rule:
+        metrics-name: service_resp_time
+        threshold: 20 # 20ms is just for demo
+        op: ">"
+        period: 5
+        count: 1
 kind: ConfigMap
 metadata:
   name: oap-static-config
@@ -178,8 +187,7 @@ spec:
               value: k8s-configmap
           volumeMounts:
             - name: config-volume
-              mountPath: /skywalking/config/metadata-service-mapping.yaml
-              subPath: metadata-service-mapping.yaml
+              mountPath: /skywalking/ext-config
       volumes:
         - name: config-volume
           configMap: