Change using service lebel metrics (#8319)
This commit is contained in:
parent
5da205ba9b
commit
05991f34a6
|
|
@ -13,22 +13,22 @@
|
|||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
expSuffix: tag({tags -> tags.service = 'satellite::' + tags.service}).instance(['service'], ['instance'])
|
||||
expSuffix: tag({tags -> tags.service = 'satellite::' + tags.service}).service(['service'])
|
||||
metricPrefix: satellite
|
||||
metricsRules:
|
||||
- name: instance_receive_event_count
|
||||
exp: sw_stl_gatherer_receive_count.sum(["pipe", "status", "service", "instance"]).increase("PT1M")
|
||||
- name: instance_fetch_event_count
|
||||
exp: sw_stl_gatherer_fetch_count.sum(["pipe", "status", "service", "instance"]).increase("PT1M")
|
||||
- name: instance_queue_input_count
|
||||
exp: sw_stl_queue_output_count.sum(["pipe", "status", "service", "instance"]).increase("PT1M")
|
||||
- name: instance_send_event_count
|
||||
exp: sw_stl_sender_output_count.sum(["pipe", "status", "service", "instance"]).increase("PT1M")
|
||||
- name: instance_queue_total_capacity
|
||||
exp: sw_stl_pipeline_queue_total_capacity.sum(["pipeline", "service", "instance"])
|
||||
- name: instance_queue_used_count
|
||||
exp: sw_stl_pipeline_queue_partition_size.sum(["pipeline", "service", "instance"])
|
||||
- name: instance_server_cpu_utilization
|
||||
- name: service_receive_event_count
|
||||
exp: sw_stl_gatherer_receive_count.sum(["pipe", "status", "service"]).increase("PT1M")
|
||||
- name: service_fetch_event_count
|
||||
exp: sw_stl_gatherer_fetch_count.sum(["pipe", "status", "service"]).increase("PT1M")
|
||||
- name: service_queue_input_count
|
||||
exp: sw_stl_queue_output_count.sum(["pipe", "status", "service"]).increase("PT1M")
|
||||
- name: service_send_event_count
|
||||
exp: sw_stl_sender_output_count.sum(["pipe", "status", "service"]).increase("PT1M")
|
||||
- name: service_queue_total_capacity
|
||||
exp: sw_stl_pipeline_queue_total_capacity.sum(["pipeline", "service"])
|
||||
- name: service_queue_used_count
|
||||
exp: sw_stl_pipeline_queue_partition_size.sum(["pipeline", "service"])
|
||||
- name: service_server_cpu_utilization
|
||||
exp: sw_stl_grpc_server_cpu_gauge
|
||||
- name: instance_grpc_connect_count
|
||||
- name: service_grpc_connect_count
|
||||
exp: sw_stl_grpc_server_connection_count
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
# 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.
|
||||
|
||||
{{- contains .}}
|
||||
- id: {{ b64enc "satellite::satellite-service" }}.1_{{ b64enc "satellite-instance" }}
|
||||
name: satellite-instance
|
||||
attributes: []
|
||||
language: UNKNOWN
|
||||
instanceuuid: {{ b64enc "satellite::satellite-service" }}.1_{{ b64enc "satellite-instance" }}
|
||||
{{- end}}
|
||||
|
|
@ -17,11 +17,8 @@
|
|||
# service list
|
||||
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql service ls
|
||||
expected: expected/satellite-service.yml
|
||||
# service instance list
|
||||
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql instance list --service-name=satellite::satellite-service
|
||||
expected: expected/satellite-service-instance.yml
|
||||
# service instance metrics
|
||||
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=satellite_instance_server_cpu_utilization --instance-name=satellite-instance --service-name=satellite::satellite-service |yq e 'to_entries' -
|
||||
# service metrics
|
||||
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=satellite_service_server_cpu_utilization --service-name=satellite::satellite-service |yq e 'to_entries' -
|
||||
expected: expected/metrics-has-value.yml
|
||||
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=satellite_instance_grpc_connect_count --instance-name=satellite-instance --service-name=satellite::satellite-service |yq e 'to_entries' -
|
||||
- query: swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=satellite_service_grpc_connect_count --service-name=satellite::satellite-service |yq e 'to_entries' -
|
||||
expected: expected/metrics-has-value.yml
|
||||
Loading…
Reference in New Issue