EMsnap commented on code in PR #5763:
URL: https://github.com/apache/inlong/pull/5763#discussion_r960718704


##########
inlong-sort/sort-connectors/pulsar/src/main/java/org/apache/inlong/sort/pulsar/table/DynamicPulsarDeserializationSchema.java:
##########
@@ -132,6 +140,40 @@ public void 
open(DeserializationSchema.InitializationContext context) throws Exc
 
     }
 
+    /**
+     * reflect get metricGroup
+     *
+     * @param context Contextual information that can be used during 
initialization.
+     * @return metric group that can be used to register new metrics with 
Flink and to create a nested hierarchy based
+     *         on the group names.
+     */
+    private MetricGroup 
getMetricGroup(DeserializationSchema.InitializationContext context)
+            throws NoSuchFieldException, IllegalAccessException {
+        MetricGroup metricGroup;
+        String className = 
"RuntimeContextDeserializationInitializationContextAdapter";
+        String fieldName = "runtimeContext";
+        Class runtimeContextDeserializationInitializationContextAdapter = null;
+        Class[] innerClazz = 
RuntimeContextInitializationContextAdapters.class.getDeclaredClasses();
+        for (Class clazz : innerClazz) {
+            int mod = clazz.getModifiers();

Review Comment:
   mod -> modifier since mod is a term in math



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to