.. _metrics_user_site: ################# User Site Metrics ################# User-site metrics describe application-layer activity for each explicit site defined under a user. Metric names use the prefix ``user.`` where *site_id* is the value of the :ref:`id ` configuration option. The following tags are present on all user-site metrics: * :ref:`daemon_group ` * :ref:`stat_id ` * user_group The user group name. * user The user name. * user_type The user type. See :ref:`user type ` for details. Request ======= The following tags are set on metrics in this section: * server The server name that received the request. Any extra tags configured on the server are also included. The following tag is also set on ``user..connection.*`` metrics: * :ref:`connection ` The following tag is also set on ``user..request.*`` metrics: * :ref:`request ` The metric names are: * user..connection.total **type**: count Number of client connections from the user for this site. Connections that fail during authentication are not counted. * user..request.total **type**: count Total requests received from the user for this site. This value may be greater than ``user..connection.total`` because some protocols can reuse a connection for multiple requests. * user..request.alive **type**: gauge Number of currently active requests for this site. * user..request.ready **type**: count Total tasks for this site that reached the *ready* stage. The remote connection may be new or a reused keepalive connection. * user..request.reuse **type**: count Total attempts to reuse an existing remote keepalive connection. Reuse attempts may still fail. * user..request.renew **type**: count Total failed attempts to reuse an existing remote keepalive connection. After a recoverable reuse failure, a new connection is created and the request is retried. * user..l7.connection.alive **type**: gauge Number of currently active layer-7 proxy connections for this site. Traffic ======= The following tags are set on metrics in this section: * :ref:`request ` * server The server name that received the request. Any extra tags configured on the server are also included. These I/O metrics include application-layer traffic only. SOCKS negotiation data and HTTPS-forward TLS overhead are not included. The metric names are: * user..traffic.in.bytes **type**: count Total bytes received from the client. * user..traffic.in.packets **type**: count Total datagram packets received from the client. This metric is not available for stream-oriented transports. * user..traffic.out.bytes **type**: count Total bytes sent to the client. * user..traffic.out.packets **type**: count Total datagram packets sent to the client. This metric is not available for stream-oriented transports. Duration ======== The following tags are set on metrics in this section: * server The server name that received the request. Any extra tags configured on the server are also included. The following tag is also set: * :ref:`quantile ` The metric names are: * user..task.ready.duration **type**: gauge Histogram summary for task ready duration, corresponding to the :ref:`ready_time ` field in the logs. Upstream Traffic ================ The following tags are set on metrics in this section: * :ref:`transport ` * escaper The escaper name that handled the upstream side of the request. Any extra tags configured on the escaper are also included. These I/O metrics include application-layer traffic only. HTTPS-forward TLS overhead is not included. The metric names are: * user..upstream.traffic.in.bytes **type**: count Total bytes received from the upstream side. * user..upstream.traffic.in.packets **type**: count Total datagram packets received from the upstream side. This metric is not available for stream-oriented transports. * user..upstream.traffic.out.bytes **type**: count Total bytes sent to the upstream side. * user..upstream.traffic.out.packets **type**: count Total datagram packets sent to the upstream side. This metric is not available for stream-oriented transports.