You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "HBG (Jira)" <ji...@apache.org> on 2022/10/17 10:05:00 UTC
[jira] [Created] (HUDI-5041) lock metric register confict error
HBG created HUDI-5041:
-------------------------
Summary: lock metric register confict error
Key: HUDI-5041
URL: https://issues.apache.org/jira/browse/HUDI-5041
Project: Apache Hudi
Issue Type: Bug
Reporter: HBG
Attachments: image-2022-10-17-17-56-27-971.png, image-2022-10-17-18-02-14-951.png
There is a chance to see this error when write data to hudi with flink, and slot number per TM is larger than 1.
java.lang.IllegalArgumentException: A metric named hudi_table1.lock.acquire.duration already exists
The cause is in constructor of HoodieLockMetrics, when different thread from different slot of a Flink TM new HoodieLockMetrics, timer of identical metricName may registered to
MetricRegistry multiple time, causing this error.
!image-2022-10-17-17-56-27-971.png!
we can add synchronized statement in function 'createTimerForMetrics' to make the test and set action atomic to avoid adding a timer multiple times.
!image-2022-10-17-18-02-14-951.png!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)