[
https://issues.apache.org/jira/browse/FLINK-22631?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17346876#comment-17346876
]
Konstantin Knauf commented on FLINK-22631:
------------------------------------------
Hi [~kanata163], thank you for you patience. As mentioned above, I tend to say
that this is the expected behavior as Flink's metrics system was built to
monitor running applications. Have you considered using accumulators [1] for
you use case?
[~chesnay] what do you think?
[1]
https://ci.apache.org/projects/flink/flink-docs-release-1.13/docs/dev/datastream/user_defined_functions/#accumulators--counters
> Metrics are incorrect when task finished
> ----------------------------------------
>
> Key: FLINK-22631
> URL: https://issues.apache.org/jira/browse/FLINK-22631
> Project: Flink
> Issue Type: Improvement
> Components: Runtime / Metrics
> Reporter: Li
> Priority: Major
> Attachments: image-2021-05-11-20-13-25-886.png,
> image-2021-05-11-20-14-29-290.png
>
>
> MetricReporters are reported periodically, default 10 seconds. The
> final metrics may not be reported to metric system like pushgateway when task
> finished. This makes users unable to obtain the correct metrics。
>
> Maybe metricReporters should be reported once manually before closed.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)