You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by ta...@apache.org on 2021/07/02 07:32:24 UTC
[flink] branch release-1.13 updated: [FLINK-22528][docs] Document
latency tracking metrics for state accesses
This is an automated email from the ASF dual-hosted git repository.
tangyun pushed a commit to branch release-1.13
in repository https://gitbox.apache.org/repos/asf/flink.git
The following commit(s) were added to refs/heads/release-1.13 by this push:
new 32c0ef1 [FLINK-22528][docs] Document latency tracking metrics for state accesses
32c0ef1 is described below
commit 32c0ef1f71be76697ffd9eb3125e3bd87d36e212
Author: Yun Tang <my...@live.com>
AuthorDate: Thu Jun 17 15:47:23 2021 +0800
[FLINK-22528][docs] Document latency tracking metrics for state accesses
---
docs/content.zh/docs/ops/metrics.md | 13 ++++++++++++-
docs/content/docs/ops/metrics.md | 13 ++++++++++++-
2 files changed, 24 insertions(+), 2 deletions(-)
diff --git a/docs/content.zh/docs/ops/metrics.md b/docs/content.zh/docs/ops/metrics.md
index e433691..fc2ab8c 100644
--- a/docs/content.zh/docs/ops/metrics.md
+++ b/docs/content.zh/docs/ops/metrics.md
@@ -1642,7 +1642,7 @@ logged by `SystemResourcesMetricsInitializer` during the startup.
</tbody>
</table>
-## Latency tracking
+## End-to-End latency tracking
Flink allows to track the latency of records travelling through the system. This feature is disabled by default.
To enable the latency tracking you must set the `latencyTrackingInterval` to a positive number in either the
@@ -1671,6 +1671,17 @@ up an automated clock synchronisation service (like NTP) to avoid false latency
of the cluster (in particular for `subtask` granularity). It is highly recommended to only use them for debugging
purposes.
+## State access latency tracking
+
+Flink also allows to track the keyed state access latency for standard Flink state-backends or customized state backends which extending from `AbstractStateBackend`. This feature is disabled by default.
+To enable this feature you must set the `state.backend.latency-track.keyed-state-enabled` to true in the [Flink configuration]({{< ref "docs/deployment/config" >}}#state-backends-latency-tracking-options).
+
+Once tracking keyed state access latency is enabled, Flink will sample the state access latency every `N` access, in which `N` is defined by `state.backend.latency-track.sample-interval`.
+This configuration has a default value of 100. A smaller value will get more accurate results but have a higher performance impact since it is sampled more frequently.
+
+As the type of this latency metrics is histogram, `state.backend.latency-track.history-size` will control the maximum number of recorded values in history, which has the default value of 128.
+A larger value of this configuration will require more memory, but will provide a more accurate result.
+
## REST API integration
Metrics can be queried through the [Monitoring REST API]({{< ref "docs/ops/rest_api" >}}).
diff --git a/docs/content/docs/ops/metrics.md b/docs/content/docs/ops/metrics.md
index 383a852..46126a9 100644
--- a/docs/content/docs/ops/metrics.md
+++ b/docs/content/docs/ops/metrics.md
@@ -1641,7 +1641,7 @@ logged by `SystemResourcesMetricsInitializer` during the startup.
</tbody>
</table>
-## Latency tracking
+## End-to-End latency tracking
Flink allows to track the latency of records travelling through the system. This feature is disabled by default.
To enable the latency tracking you must set the `latencyTrackingInterval` to a positive number in either the
@@ -1670,6 +1670,17 @@ up an automated clock synchronisation service (like NTP) to avoid false latency
of the cluster (in particular for `subtask` granularity). It is highly recommended to only use them for debugging
purposes.
+## State access latency tracking
+
+Flink also allows to track the keyed state access latency for standard Flink state-backends or customized state backends which extending from `AbstractStateBackend`. This feature is disabled by default.
+To enable this feature you must set the `state.backend.latency-track.keyed-state-enabled` to true in the [Flink configuration]({{< ref "docs/deployment/config" >}}#state-backends-latency-tracking-options).
+
+Once tracking keyed state access latency is enabled, Flink will sample the state access latency every `N` access, in which `N` is defined by `state.backend.latency-track.sample-interval`.
+This configuration has a default value of 100. A smaller value will get more accurate results but have a higher performance impact since it is sampled more frequently.
+
+As the type of this latency metrics is histogram, `state.backend.latency-track.history-size` will control the maximum number of recorded values in history, which has the default value of 128.
+A larger value of this configuration will require more memory, but will provide a more accurate result.
+
## REST API integration
Metrics can be queried through the [Monitoring REST API]({{< ref "docs/ops/rest_api" >}}).