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

expSuffix: service(['service'], Layer.SO11Y_SATELLITE)
metricPrefix: satellite
metricsRules:
  - 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: service_grpc_connect_count
    exp: sw_stl_grpc_server_connection_count
