-[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.
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.
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.