[
https://issues.apache.org/jira/browse/FLINK-23433?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17385322#comment-17385322
]
Jingsong Lee commented on FLINK-23433:
--------------------------------------
Sorry, I am not familiar to the metrics...
> Metrics cannot be initialized in format
> ---------------------------------------
>
> Key: FLINK-23433
> URL: https://issues.apache.org/jira/browse/FLINK-23433
> Project: Flink
> Issue Type: Bug
> Components: Formats (JSON, Avro, Parquet, ORC, SequenceFile)
> Affects Versions: 1.11.3
> Reporter: Fangliang Liu
> Priority: Major
>
>
> I want to use metrics in a custom format, I wrote it like this
> {code:java}
> ProtobufRowDeserializationSchema implements DeserializationSchema<Row>{
> private transient MetricGroup metrics;
> @Override
> public void open(InitializationContext context) throws Exception {
> metrics = context.getMetricGroup();
> }
> }
> {code}
> But, received an `metrics` NPE. it stands to reason that the metrics have
> already been initialized.
>
> [~jark], [~lzljs3620320] , Looking forward to your reply.
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)