.. _envoy_v3_api_file_envoy/config/metrics/v3/metrics_service.proto:

Metrics service
===============


.. _envoy_v3_api_msg_config.metrics.v3.MetricsServiceConfig:

config.metrics.v3.MetricsServiceConfig
--------------------------------------

`[config.metrics.v3.MetricsServiceConfig proto] <https://github.com/envoyproxy/envoy/blob/e98e41a8e168af7acae8079fc0cd68155f699aa3/api/envoy/config/metrics/v3/metrics_service.proto#L24>`_

Metrics Service is configured as a built-in *envoy.stat_sinks.metrics_service* :ref:`StatsSink
<envoy_v3_api_msg_config.metrics.v3.StatsSink>`. This opaque configuration will be used to create
Metrics Service.

.. _extension_envoy.stat_sinks.metrics_service:


This extension may be referenced by the qualified name *envoy.stat_sinks.metrics_service*

.. note::
  

  This extension does not operate on the data plane and hence is intended to be robust against untrusted traffic.

.. code-block:: json

  {
    "grpc_service": "{...}",
    "transport_api_version": "...",
    "report_counters_as_deltas": "{...}"
  }

.. _envoy_v3_api_field_config.metrics.v3.MetricsServiceConfig.grpc_service:

grpc_service
  (:ref:`config.core.v3.GrpcService <envoy_v3_api_msg_config.core.v3.GrpcService>`, *REQUIRED*) The upstream gRPC cluster that hosts the metrics service.
  
  
.. _envoy_v3_api_field_config.metrics.v3.MetricsServiceConfig.transport_api_version:

transport_api_version
  (:ref:`config.core.v3.ApiVersion <envoy_v3_api_enum_config.core.v3.ApiVersion>`) API version for metric service transport protocol. This describes the metric service gRPC
  endpoint and version of messages used on the wire.
  
  
.. _envoy_v3_api_field_config.metrics.v3.MetricsServiceConfig.report_counters_as_deltas:

report_counters_as_deltas
  (`BoolValue <https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#boolvalue>`_) If true, counters are reported as the delta between flushing intervals. Otherwise, the current
  counter value is reported. Defaults to false.
  Eventually (https://github.com/envoyproxy/envoy/issues/10968) if this value is not set, the
  sink will take updates from the :ref:`MetricsResponse <envoy_v3_api_msg_service.metrics.v3.StreamMetricsResponse>`.