wu-sheng commented on code in PR #9822:
URL: https://github.com/apache/skywalking/pull/9822#discussion_r1002499932


##########
oap-server/analyzer/meter-analyzer/src/main/java/org/apache/skywalking/oap/meter/analyzer/prometheus/rule/Rules.java:
##########
@@ -47,29 +50,72 @@ public static List<Rule> loadRules(final String path) 
throws ModuleStartExceptio
     public static List<Rule> loadRules(final String path, List<String> 
enabledRules) throws ModuleStartException {
         File[] rules;
         try {
-            rules = ResourceUtils.getPathFiles(path);
+            rules = ResourceUtils.getAllPathFiles(path);
         } catch (FileNotFoundException e) {
             throw new ModuleStartException("Load fetcher rules failed", e);
         }
+        final List<String> formedEnabledRules =

Review Comment:
   Unit Tests. The path/file pattern mechanism is added newly, and it is better 
if you could test through correct input and wrong put with predictable 
results(correct file list or exception or empty list) 



-- 
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