mayankkunwar commented on code in PR #4630:
URL: https://github.com/apache/hive/pull/4630#discussion_r1316867146
##########
standalone-metastore/metastore-common/src/test/java/org/apache/hadoop/hive/common/metrics/metrics2/TestCodahaleReportersConf.java:
##########
@@ -149,4 +151,31 @@ public void testNoFallbackOnIncorrectConf() throws
Exception {
Assert.assertFalse(jsonReportFile.exists());
}
+
+ /**
+ * Tests if MetricsFactory is initialised properly, if in case
Metrics2Reporter is tried to add more than once.
+ *
+ * **/
+ @Test
+ public void testMetricsFactoryInitMetrics2ReporterAddedTwice() throws
Exception {
+ if(MetricsFactory.getInstance() != null) {
Review Comment:
Okay I will refactor the code
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]