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 2019/01/01 03:09:17 UTC

[incubator-skywalking] 01/01: Fix doc.

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

wusheng pushed a commit to branch doc
in repository https://gitbox.apache.org/repos/asf/incubator-skywalking.git

commit 38f514865ebad868f52cfa594cc23ee58cc72657
Author: Wu Sheng <wu...@foxmail.com>
AuthorDate: Tue Jan 1 11:09:02 2019 +0800

    Fix doc.
---
 docs/en/concepts-and-designs/README.md             |  2 +-
 docs/en/concepts-and-designs/query-oap.md          | 38 -------------
 docs/en/guides/backend-oal-scripts.md              |  5 +-
 docs/en/protocols/README.md                        | 63 +++++++++++++++++++++-
 .../oap/server/core/storage/PersistenceTimer.java  |  2 +-
 5 files changed, 66 insertions(+), 44 deletions(-)

diff --git a/docs/en/concepts-and-designs/README.md b/docs/en/concepts-and-designs/README.md
index 2da553f..a3404c9 100644
--- a/docs/en/concepts-and-designs/README.md
+++ b/docs/en/concepts-and-designs/README.md
@@ -18,6 +18,6 @@ SkyWalking already support.
 - Backend
   - [Overview](backend-overview.md). Provides a high level introduction about the OAP backend.
   - [Observability Analysis Language](oal.md). Introduces the core languages, which is designed for aggregation behaviour definition.
-  - [Query in OAP](query-oap.md). Introduces how to query data from backend, whether a simple metric data or topology map, even trace or log.
+  - [Query in OAP](../protocols/README.md#query-protocol). A set of query protocol provided, based on the Observability Analysis Language metric definition. 
 - UI
   - [Overview](ui-overview.md).
diff --git a/docs/en/concepts-and-designs/query-oap.md b/docs/en/concepts-and-designs/query-oap.md
deleted file mode 100644
index 3e72990..0000000
--- a/docs/en/concepts-and-designs/query-oap.md
+++ /dev/null
@@ -1,38 +0,0 @@
-# Query in OAP
-Query(s) are provided in GraphQL format. All GraphQL definition files are [here](../../../oap-server/server-query-plugin/query-graphql-plugin/src/main/resources/query-protocol).
-
-Here are the explanation of these definitions.
-
-## Common Objects
-All objects defined in `common.graphqls` are simple common objects, which could be used in any other 
-`*.graphqls` definition files. Such as, **Duration**, **Step**, **Scope**.
-
-## Metadata
-Through Metadata query(s) which defined in `metadata.graphqls`, you could have the meta info of Service, Service Instance and Endpoint, 
-including name, id, relationship. 
-
-## Metric
-Metric query(s) in `metric.graphqls` could be used to fetch data from any variable defined in **OAL** scripts. 
-You could read value or linear trend of the metric variable by the given duration and id.
-
-Also, Thermodynamic heatmap is very different with other single value metric, so it is a special
-query op. **Thermodynamic** object, a data matrix, will be returned to represent.
-
-## Aggregation Query
-Aggregation query(s) in `aggregation.graphs` right now, are most TopN related query(s). You could 
-get **TopN** service, service instance and endpoint in different ways.
-
-## Topology Query
-Topology query(s) in `topology.graphqls` provide the consistency query no matter what sources do you 
-get the topology relation. Also, all entity IDs included in topology will be returned too, for your 
-convenience to do metric query(s).
-
-## Trace
-At beginning and some scenarios, SkyWalking will be considered as a distributed tracing system. So
-of course we will provide trace query. In `trace.graphql` you will find the format, it is nearly the 
-same format of our trace report/uplink protocol, just in GraphQL version. 
-
-## Alarm
-Alarm query(s) in `alarm.graphql` could be get triggered alarms. Although we believe alarm webhook
-in alarm settings(see [alarm setting doc](../setup/backend/backend-alarm.md)) will be more useful
-and powerful, still we provide query for SkyWalking UI or simple use scenarios.
diff --git a/docs/en/guides/backend-oal-scripts.md b/docs/en/guides/backend-oal-scripts.md
index 2912a02..6c79a9c 100644
--- a/docs/en/guides/backend-oal-scripts.md
+++ b/docs/en/guides/backend-oal-scripts.md
@@ -2,12 +2,11 @@
 First, read [OAL introduction](../concepts-and-designs/oal.md).
 
 Here is the official scrips is the `generated-analysis-x.y.z.jar/official_analysis.oal` file in distribution,
-also the `server-core` module's **src/main/resources/official_analysis.oal** in source code repository.
+also the [official_analysis.oal](../../../oap-server/generated-analysis/src/main/resources/official_analysis.oal) in source code repository.
 
 **Notice**, this file doesn't effect anything in runtime, although included in distribution.
 You need to use OAL tool code generator to build the real analysis codes from it.
-All generated codes are under **org.apache.skywalking.oap.server.core.analysis.generated** package
-in `server-core` module. 
+All generated codes are under `oal` folder in **oap-server/generated-analysis/target/generated-sources**.
 
 All metrics named in this script could be used in alarm and UI query. Of course, you can change this 
 scripts and re-generate the analysis process and metric, such as adding filter condition. 
diff --git a/docs/en/protocols/README.md b/docs/en/protocols/README.md
index fdeae69..160b7c9 100644
--- a/docs/en/protocols/README.md
+++ b/docs/en/protocols/README.md
@@ -75,4 +75,65 @@ by the values.
 1. Trace. Query distributed traces by this.
 1. Alarm. Through alarm query, you can have alarm trend and details.
 
-The actual query GraphQL scrips could be found inside `query-protocol` folder in [here](../../../oap-server/server-query-plugin/query-graphql-plugin/src/main/resources).  
+The actual query GraphQL scrips could be found inside `query-protocol` folder in [here](../../../oap-server/server-query-plugin/query-graphql-plugin/src/main/resources).
+
+Here is the list of all existing metric names, based on [official_analysis.oal](../../../oap-server/generated-analysis/src/main/resources/official_analysis.oal)
+
+**Global metric**
+- all_p99, p99 response time of all services
+- all_p95
+- all_p90
+- all_p75
+- all_p70
+- all_heatmap, the response time heatmap of all services 
+
+**Service metric**
+- service_resp_time, avg response time of service
+- service_sla, successful rate of service
+- service_cpm, calls per minute of service
+- service_p99, p99 response time of service
+- service_p95
+- service_p90
+- service_p75
+- service_p50
+
+**Service instance metric**
+- service_instance_sla, successful rate of service instance
+- service_instance_resp_time, avg response time of service instance
+- service_instance_cpm, calls per minute of service instance
+
+**Endpoint metric**
+- endpoint_cpm, calls per minute of endpoint
+- endpoint_avg, avg response time of endpoint
+- endpoint_sla, successful rate of endpoint
+- endpoint_p99, p99 response time of endpoint
+- endpoint_p95
+- endpoint_p90
+- endpoint_p75
+- endpoint_p50
+
+**JVM metric**, JVM related metric, only work when javaagent is active
+- instance_jvm_cpu
+- instance_jvm_memory_heap
+- instance_jvm_memory_noheap
+- instance_jvm_memory_heap_max
+- instance_jvm_memory_noheap_max
+- instance_jvm_young_gc_time
+- instance_jvm_old_gc_time
+- instance_jvm_young_gc_count
+- instance_jvm_old_gc_count
+
+**Service relation metric**, represents the metric of calls between service. 
+The metric ID could be
+got in topology query only.
+- service_relation_client_cpm, calls per minut detected at client side
+- service_relation_server_cpm, calls per minut detected at server side
+- service_relation_client_call_sla, successful rate detected at client side
+- service_relation_server_call_sla, successful rate detected at server side
+- service_relation_client_resp_time, avg response time detected at client side
+- service_relation_server_resp_time, avg response time detected at client side
+
+**Endpoint relation metric**, represents the metric between dependency endpoints. Only work when tracing agent.
+The metric ID could be got in topology query only.
+- endpoint_relation_cpm
+- endpoint_relation_resp_time
\ No newline at end of file
diff --git a/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/storage/PersistenceTimer.java b/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/storage/PersistenceTimer.java
index 63d3a81..8cde887 100644
--- a/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/storage/PersistenceTimer.java
+++ b/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/storage/PersistenceTimer.java
@@ -37,7 +37,7 @@ public enum PersistenceTimer {
     private final Boolean debug;
 
     PersistenceTimer() {
-        this.debug = System.getProperty("debug") != null;
+        this.debug = SysteElasticSearchEnhanceInfom.getProperty("debug") != null;
     }
 
     public void start(ModuleManager moduleManager) {